@routecraft/prettier-plugin-routecraft weekly downloads statistics
By routecraft · npm · Prettier plugins
Prettier plugin for compact Routecraft DSL formatting
@routecraft/prettier-plugin-routecraft has 172 recorded weekly downloads on npm, a decrease of 83.4% over the past 30 days, ranking #1723 of 2,391 tracked listings.
About @routecraft/prettier-plugin-routecraft
@routecraft/prettier-plugin-routecraft
Prettier plugin that keeps Routecraft DSL chains compact and readable.
Prettier's defaults push fluent sub-pipeline path closures onto their own line
and add an extra level of indentation for every (b) => b... branch builder
inside .choice() and .multicast(). This plugin overrides Prettier's printer
for those closures so the threaded parameter stays on the arrow line and the
chain keeps a single indent level.
Before and after
// Prettier default
.choice(
when(senderInAllowlist(env.MAIL_ALLOWED_INBOUND), (b) =>
b
.enrich(agent("zoe"), only((r) => r, "agent"))
.to(mail({ action: "move" })),
),
otherwise((b) => b),
)
// With @routecraft/prettier-plugin-routecraft
.choice(
when(senderInAllowlist(env.MAIL_ALLOWED_INBOUND), (b) => b
.enrich(agent("zoe"), only((r) => r, "agent"))
.to(mail({ action: "move" }))),
otherwise((b) => b),
)
Installation
# Bun (recommended)
bun add -D @routecraft/prettier-plugin-routecraft prettier
# npm / pnpm / yarn
npm install --save-dev @routecraft/prettier-plugin-routecraft prettier
pnpm add -D @routecraft/prettier-plugin-routecraft prettier
yarn add -D @routecraft/prettier-plugin-routecraft prettier
Requirements
- Prettier >= 3
Usage
Add the plugin to your Prettier configuration:
// prettier.config.mjs
export default {
plugins: ["@routecraft/prettier-plugin-routecraft"],
};
Or in .prettierrc:
{
"plugins": ["@routecraft/prettier-plugin-routecraft"]
}
Then format as usual:
bunx prettier --write .
What it touches
The plugin only changes parameter-threaded builders: single-parameter arrow
closures whose body is a fluent chain rooted in that parameter, passed directly
as a call argument inside a craft() chain. Arrows such as
(b) => b.enrich(...).to(...) (a branch builder inside when(...) /
otherwise(...) / multicast(...)) keep the parameter on the arrow line
instead of breaking the body onto its own line.
Everything else is left to Prettier's defaults, including factory-rooted
callbacks such as (ex) => direct(...).send(...) (whose chain is rooted in a
call, not the parameter), ordinary arr.map((x) => x.foo()) chains (no
craft() root), arrows used as object or array values such as adapter option
callbacks (path: (ex) => path.join(...)), non-chain bodies such as template
literals or object literals, and async arrows or arrows with explicit return
types or type parameters (so no type information is ever dropped).
Documentation
For more information about Routecraft, visit routecraft.dev.
License
Apache-2.0
Links
Description from the npm listing.
- prettier
- prettier-plugin
- routecraft
- formatting
- typescript
README badge
Show your rank in a README or on your website. The badge updates automatically.
Charts
Images: 30d · 1y · all time · 1600×900 dark
Adoption over time
7/30/90-day growth
Ranking history
Listing placement
Listing placement
Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.
Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.
Recent observations
Full history (122)Similar npm Prettier plugins plugins
All 20 @routecraft/prettier-plugin-routecraft alternativesData source
Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.
Listing: https://www.npmjs.com/package/@routecraft/prettier-plugin-routecraft. First seen Oct 16, 2026; last successful collection Oct 21, 2026. See the methodology.