Skip to content
PluginStats

prettier-plugin-angular-comment weekly downloads statistics

By Angular-RU · npm · Prettier plugins

Format Angular templates in JS/TS template literals with /* Angular */

View on npm Fresh · Oct 28, 2026

prettier-plugin-angular-comment has 40 recorded weekly downloads on npm, ranking #1781 of 2,644 tracked listings.

Weekly downloads
40
Official API · Oct 26, 2026
7-day growth
—
Insufficient history
30-day growth
—
Insufficient history
90-day growth
—
Insufficient history
Rank
#1781
Among tracked npm listings

About prettier-plugin-angular-comment

prettier-plugin-angular-comment

Format Angular template literals in JavaScript and TypeScript with an explicit /* Angular */ marker.

Community plugin implementing the behavior proposed in prettier/prettier#20317 for #17615, without changing Prettier core.

Install

npm install -D prettier prettier-plugin-angular-comment

Configure Prettier:

{ "plugins": ["prettier-plugin-angular-comment"] }

Usage

const template = /* Angular */ `
  @if (visible) {
    <span>{{ name }}</span>
  } @else {
    <span>Hidden</span>
  }
`;

The marker is case sensitive and applies only to the following template literal. Existing HTML comments, normal templates, and Angular component templates continue to use Prettier's built-in formatting. JS template expressions (${value}) are supported. Changing whitespace inside a template can change its runtime string value; opt in only where appropriate.

API

import * as prettier from "prettier";
import * as plugin from "prettier-plugin-angular-comment";
const result = await prettier.format(source, { parser: "typescript", plugins: [plugin] });

Set embeddedLanguageFormatting: "off" to disable the plugin's embedding, along with other embedded formatting.

Requirements and limitations

  • Prettier 3.x / Node 18+.
  • Supports JS/TS parsers backed by the built-in estree printer.
  • May conflict with another plugin that also overrides estree.embed. Check plugin order.
  • Invalid Angular embedded syntax falls back to normal formatting, consistent with Prettier's embed error handling.

Development

npm install
npm test
npm pack --dry-run

npm releases (Trusted Publishing / OIDC)

This repository uses npm Trusted Publishing with GitHub Actions. No persistent NPM_TOKEN or NODE_AUTH_TOKEN secret is required.

First release (one-time setup)

npm requires the package to exist before a Trusted Publisher can be configured. If the package has not been published yet, its npm owner must bootstrap it locally:

npm login
npm install
npm test
npm publish --access public

Keep the version in package.json synchronized with the first published version. Do not push a matching tag for the manually published version.

Enable Trusted Publishing
  1. Open https://www.npmjs.com/package/prettier-plugin-angular-comment/access or the package's npm settings, then Trusted publishing → Add trusted publisher → GitHub Actions.
  2. Enter Organization/user: Angular-RU, Repository: prettier-plugin-angular-comment, Workflow filename: publish.yml (not a path), Environment: npm-publish.
  3. Enable Allow npm publish in the npm trusted publisher's allowed actions. Staging-only permission is insufficient for this workflow.
  4. In GitHub Settings → Environments, create or configure npm-publish. Add required reviewers and deployment-tag restrictions if desired, so a release requires approval.
  5. Complete the first successful OIDC publication within 2 days of creating the trusted publisher, or recreate the expired configuration.
Publish the next version

Update package.json to an unpublished version (for example, 0.1.2), merge it to main, and confirm CI is green. Then push the corresponding tag from a commit on main:

git switch main
git pull --ff-only
git tag v0.1.2
git push origin v0.1.2

The publish workflow verifies the exact version and that the tag commit is on main, runs tests without OIDC permissions, and publishes in a separate approval-gated environment. The publisher job disables npm lifecycle scripts and uses npm's short-lived OIDC authentication and automatic provenance. Pinned GitHub Action commit SHAs and disabled release-job caching reduce supply-chain risk.

After the first successful OIDC release, consider selecting Require two-factor authentication and disallow tokens under npm Settings → Publishing access, and protect release tags with a GitHub ruleset. Traditional npm token publishing will then be blocked while OIDC continues working.

License

MIT

Description from the npm listing.

  • prettier
  • prettier-plugin
  • angular
  • template-literals

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

prettier-plugin-angular-comment weekly downloads on npm, last 90 days: 40 weekly downloads as of Oct 26, 2026.prettier-plugin-angular-commentWeekly downloads on npm · Last 90 days40downloads / week152025303540Jul 28Aug 12Aug 27Sep 11Sep 26Oct 11Oct 26downloads / weekobservedarchived (Internet Archive)no observationsOct 22, 2026 – Oct 26, 2026 · 2 observations · Updated Oct…pluginstats.com
prettier-plugin-angular-comment weekly downloads on npm, last 90 days: 40 weekly downloads as of Oct 26, 2026.

7/30/90-day growth

prettier-plugin-angular-comment weekly downloads growth on npm: 7-day growth unavailable, 30-day growth unavailable, 90-day growth unavailable.prettier-plugin-angular-commentWeekly downloads growth on npm40downloads / week now7-day growthinsufficient historyInsufficient history30-day growthinsufficient historyInsufficient history90-day growthinsufficient historyInsufficient historyGrowth vs. nearest observation to each baseline date · Updated Oct 26, 2026pluginstats.com
prettier-plugin-angular-comment weekly downloads growth on npm: 7-day growth unavailable, 30-day growth unavailable, 90-day growth unavailable.

Ranking history

prettier-plugin-angular-comment npm ranking history: currently #1781 (by weekly downloads).prettier-plugin-angular-commentnpm ranking · by weekly downloads · Last 90 days#1781current rank#1779#1780#1781#1782#1783Jul 30Aug 14Aug 29Sep 13Sep 28Oct 13Oct 28rankOct 28, 2026 – Oct 28, 2026 · 1 observations · Updated Oct 26, 2026pluginstats.com
prettier-plugin-angular-comment npm ranking history: currently #1781 (by weekly downloads).

Listing placement

All npm2,642 listings · 133 pages · 1,322 shown · page 108, #7 (overall #2,147)
All npm: every listing in weekly downloads order

Listing placement

Prettier plugins247 listings · 13 pages · page 5, #1 (overall #81)
Prettier plugins: every listing in weekly downloads order

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 (2)
Recent weekly downloads observations for prettier-plugin-angular-comment
Date (UTC)Weekly downloadsChange vs. previous
40+22
18—

Similar npm Prettier plugins plugins

All 20 prettier-plugin-angular-comment alternatives

Data 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-angular-comment. First seen Oct 20, 2026; last successful collection Oct 28, 2026. See the methodology.