prettier-plugin-fusion weekly downloads statistics
By serpent213 · npm · Prettier plugins
Prettier plugin for Neos Fusion/AFX files
prettier-plugin-fusion has 1 recorded weekly downloads on npm, a decrease of 85.7% over the past 30 days, ranking #2209 of 2,306 tracked listings.
About prettier-plugin-fusion
Prettier plugin for Neos CMS Fusion/AFX files
ALPHA SOFTWARE – HANDLE WITH CARE! OUTPUT FORMAT NOT STABLE YET!
This is a Prettier plugin that understands Neos Fusion/AFX syntax through
the ts-fusion-parser. The parser is production proven (it powers the
Neos Fusion VS Code extension) and can parse Fusion code, embedded AFX markup, and inline (unparsed) Eel expressions.
The printer mirrors the parser’s object model and emits Prettier docs, which means Fusion statements, nested blocks, embedded AFX templates, and inline Eel expressions are formatted consistently.
Usage
npm install --save-dev prettier-plugin-fusion
yarn add--dev prettier-plugin-fusion
pnpm install --save-dev prettier-plugin-fusion
bun add --development prettier-plugin-fusion
Add to your .prettierrc.js:
module.exports = {
plugins: [require.resolve("prettier-plugin-fusion")]
}
...and run:
# Format Fusion files in-place
prettier --write "src/**/*.fusion"
The plugin registers a fusion parser and handles .fusion files automatically. It ships a couple of parser
options that mirror the ts-fusion-parser configuration:
| Option | Default | Description |
|---|---|---|
fusionContextPath | undefined | Optional context path forwarded to the parser (defaults to Prettier's filepath). |
fusionIgnoreParserErrors | false | Set to true to keep formatting resilient while typing by collecting parser errors instead of throwing. |
fusionAllowIncompleteObjectStatements | false | Set to true when you want to allow unfinished Fusion object statements while editing. |
fusionAllowIncompleteEelPaths | true | Allows incomplete Eel object paths. |
fusionAllowUnclosedAfxTags | true | Lets the AFX parser auto-close tags the way the VS Code tooling does. |
Funktionsweise
-
Fusion: The plugin registers a
fusionparser backed byts-fusion-parser, which returns a strongly typed AST of statements, object paths, blocks, and comments. The printer insrc/printer/index.tswalks that AST and rebuilds it following an algorithm. -
AFX/HTML: When a DSL expression is marked as
afx, theembedhook normalises leading/trailing whitespace, masks embedded Eel placeholders, and lets Prettier’shtmlparser format the inner markup. The result is restored and wrapped back into theafx`...`fence. -
Eel:
${...}is treated as a string value (that’s whatts-fusion-parsergives us). We keep the original text as the source of truth, normalise whitespace, split logical operators onto continuation lines when they spill past the print width, and break long function-call arguments heuristically. There is no dedicated Eel AST here, so formatting falls back to these best-effort string transforms rather than semantic reprinting.
Development
pnpm install
pnpm test:lib
pnpm test:lib builds the TypeScript sources and runs Vitest over the fixtures in ./fixtures/fusion. Each fixture
directory contains an input.fusion and output.fusion file – the former stays intentionally unformatted while the
latter acts as the golden copy for regression testing.
Need to inspect the parser output for a particular file? Run the helper script:
ts-node scripts/inspect-ast.ts fixtures/fusion/Card/input.fusion
src/index.ts wires up Prettier with the ts-fusion-parser, while src/printer/ hosts the printer logic and doc
builder helpers.
Description from the npm listing.
- prettier-plugin
- template
- boilerplate
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 prettier-plugin-fusion 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/prettier-plugin-fusion. First seen Oct 16, 2026; last successful collection Oct 20, 2026. See the methodology.