Context
src/components/Comments.astro is the one source file .prettierignore exempts (added in #38). prettier-plugin-astro cannot parse it:
[error] src/components/Comments.astro: SyntaxError: CssSyntaxError: Unknown word ` (19:9)
The component guards everything behind {enabled && ( … )} so a default build ships zero Giscus bytes. Inside that expression the children parse as JSX, so raw CSS braces would be read as expressions — the <style is:inline>{\…`}</style>template literal is what makes scoped CSS possible there. The plugin chokes on the backtick. Rewriting it asset:html` would move the CSS out of the markup purely to satisfy the formatter, so the file is ignored and CONTRIBUTING.md asks contributors to keep it tidy by hand.
Nothing currently prompts anyone to revisit this, which is what this issue is for.
Scope
- Find or file the corresponding upstream issue on
withastro/prettier-plugin-astro and link it here.
- On each plugin bump, re-test:
npx prettier --ignore-path /dev/null --check src/components/Comments.astro
- When it parses, drop the file (and its explanatory comment) from
.prettierignore, run npm run format, and remove the "keep that file tidy by hand" sentence from CONTRIBUTING.md.
Acceptance criteria
- The command above exits 0.
.prettierignore lists only CHANGELOG.md among tracked source files.
- Formatting
Comments.astro produces no rendered-output change — the built dist/ for a Giscus-enabled config is unchanged.
Context
src/components/Comments.astrois the one source file.prettierignoreexempts (added in #38).prettier-plugin-astrocannot parse it:The component guards everything behind
{enabled && ( … )}so a default build ships zero Giscus bytes. Inside that expression the children parse as JSX, so raw CSS braces would be read as expressions — the<style is:inline>{\…`}</style>template literal is what makes scoped CSS possible there. The plugin chokes on the backtick. Rewriting it asset:html` would move the CSS out of the markup purely to satisfy the formatter, so the file is ignored and CONTRIBUTING.md asks contributors to keep it tidy by hand.Nothing currently prompts anyone to revisit this, which is what this issue is for.
Scope
withastro/prettier-plugin-astroand link it here..prettierignore, runnpm run format, and remove the "keep that file tidy by hand" sentence from CONTRIBUTING.md.Acceptance criteria
.prettierignorelists onlyCHANGELOG.mdamong tracked source files.Comments.astroproduces no rendered-output change — the builtdist/for a Giscus-enabled config is unchanged.