From 0cae7c1aa7cedd3a649fd4cb0c2aab9f8da0aea2 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Tue, 7 Oct 2025 13:06:05 +0100 Subject: [PATCH 1/6] feat: update HTML section of languages --- astro.config.ts | 14 +- package.json | 16 +- pnpm-lock.yaml | 165 ++++++++++-------- .../docs/internals/language-support.mdx | 101 ++++++----- src/content/docs/reference/configuration.mdx | 11 +- 5 files changed, 160 insertions(+), 147 deletions(-) diff --git a/astro.config.ts b/astro.config.ts index 3ba52e486..1a7409dd8 100644 --- a/astro.config.ts +++ b/astro.config.ts @@ -216,7 +216,6 @@ export default defineConfig({ { label: "Use Biome in big projects", link: "/guides/big-projects", - badge: "updated", translations: { es: "Usar Biome en proyectos grandes", fr: "Utiliser Biome dans de gros projets", @@ -231,7 +230,6 @@ export default defineConfig({ { label: "Upgrade to Biome v2", link: "/guides/upgrade-to-biome-v2", - badge: "new", translations: { ja: "Biome v2へのアップグレード", "zh-CN": "升级到 Biome v2", @@ -422,10 +420,6 @@ export default defineConfig({ { label: "Introduction", link: "/linter", - badge: { - text: "updated", - variant: "success", - }, translations: { es: "Introducción", ja: "イントロダクション", @@ -439,7 +433,6 @@ export default defineConfig({ { label: "Domains", link: "/linter/domains", - badge: "new", translations: { ja: "ドメイン", "zh-CN": "域", @@ -450,7 +443,6 @@ export default defineConfig({ { label: "Plugins", link: "/linter/plugins", - badge: "beta", translations: { ja: "プラグイン", "zh-CN": "插件", @@ -555,7 +547,6 @@ export default defineConfig({ }, { label: "Assist", - badge: "new", items: [ { label: "Introduction", @@ -679,7 +670,6 @@ export default defineConfig({ { label: "Diagnostics", link: "/reference/diagnostics", - badge: "new", translations: { es: "Diagnósticos", ja: "診断", @@ -851,6 +841,10 @@ export default defineConfig({ { label: "Language support", link: "/internals/language-support", + badge: { + text: "updated", + variant: "note", + }, translations: { es: "Soporte de lenguas", fr: "Langages pris en charge", diff --git a/package.json b/package.json index 615624538..781fa99b1 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,7 @@ "@astrojs/prism": "3.3.0", "@astrojs/react": "4.4.0", "@astrojs/rss": "4.0.12", - "@astrojs/starlight": "0.35.3", + "@astrojs/starlight": "0.36.0", "@biomejs/biome": "2.2.5", "@biomejs/wasm-web": "https://pkg.pr.new/biomejs/biome/@biomejs/wasm-web@6fcbc07", "@codemirror/lang-css": "6.3.1", @@ -71,14 +71,17 @@ "rehype-slug": "6.0.0", "remark-toc": "9.0.0", "sharp": "0.34.4", - "starlight-blog": "0.24.1", - "starlight-links-validator": "0.17.2", + "starlight-blog": "0.24.2", + "starlight-links-validator": "0.18.0", "textlint": "15.2.2", "textlint-rule-preset-jtf-style": "3.0.3", "textlint-rule-prh": "6.1.0", "typescript": "5.9.3", "vite": "6.3.6", - "vite-plugin-svgr": "4.3.0" + "vite-plugin-svgr": "4.3.0", + "@biomejs/version-utils": "^0.4.0", + "starlight-changelogs": "^0.2.1", + "textlint-filter-rule-comments": "^1.2.2" }, "packageManager": "pnpm@10.14.0", "pnpm": { @@ -86,10 +89,5 @@ "@biomejs/version-utils": "^0.4.0", "shiki": "3.9.2" } - }, - "dependencies": { - "@biomejs/version-utils": "^0.4.0", - "starlight-changelogs": "^0.2.1", - "textlint-filter-rule-comments": "^1.2.2" } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 9c3887cf3..16b5c4bf5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -11,16 +11,6 @@ overrides: importers: .: - dependencies: - '@biomejs/version-utils': - specifier: ^0.4.0 - version: 0.4.0 - starlight-changelogs: - specifier: ^0.2.1 - version: 0.2.2(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) - textlint-filter-rule-comments: - specifier: ^1.2.2 - version: 1.2.2(textlint@15.2.2) devDependencies: '@astrojs/check': specifier: 0.9.4 @@ -41,11 +31,14 @@ importers: specifier: 4.0.12 version: 4.0.12 '@astrojs/starlight': - specifier: 0.35.3 - version: 0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + specifier: 0.36.0 + version: 0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) '@biomejs/biome': specifier: 2.2.5 version: 2.2.5 + '@biomejs/version-utils': + specifier: ^0.4.0 + version: 0.4.0 '@biomejs/wasm-web': specifier: https://pkg.pr.new/biomejs/biome/@biomejs/wasm-web@6fcbc07 version: https://pkg.pr.new/biomejs/biome/@biomejs/wasm-web@6fcbc07 @@ -81,7 +74,7 @@ importers: version: 0.1.1 '@lunariajs/starlight': specifier: 0.1.1 - version: 0.1.1(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + version: 0.1.1(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) '@playwright/test': specifier: 1.55.1 version: 1.55.1 @@ -161,14 +154,20 @@ importers: specifier: 0.34.4 version: 0.34.4 starlight-blog: - specifier: 0.24.1 - version: 0.24.1(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + specifier: 0.24.2 + version: 0.24.2(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + starlight-changelogs: + specifier: ^0.2.1 + version: 0.2.1(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) starlight-links-validator: - specifier: 0.17.2 - version: 0.17.2(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))) + specifier: 0.18.0 + version: 0.18.0(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))) textlint: specifier: 15.2.2 version: 15.2.2 + textlint-filter-rule-comments: + specifier: ^1.2.2 + version: 1.2.2(textlint@15.2.2) textlint-rule-preset-jtf-style: specifier: 3.0.3 version: 3.0.3 @@ -211,9 +210,6 @@ packages: '@astrojs/compiler@2.12.2': resolution: {integrity: sha512-w2zfvhjNCkNMmMMOn5b0J8+OmUaBL1o40ipMvqcG6NRpdC+lKxmTi48DT8Xw0SzJ3AfmeFLB45zXZXtmbsjcgw==} - '@astrojs/internal-helpers@0.7.1': - resolution: {integrity: sha512-7dwEVigz9vUWDw3nRwLQ/yH/xYovlUA0ZD86xoeKEBmkz9O6iELG1yri67PgAPW6VLL/xInA4t7H0CK6VmtkKQ==} - '@astrojs/internal-helpers@0.7.2': resolution: {integrity: sha512-KCkCqR3Goym79soqEtbtLzJfqhTWMyVaizUi35FLzgGSzBotSw8DB1qwsu7U96ihOJgYhDk2nVPz+3LnXPeX6g==} @@ -232,9 +228,6 @@ packages: prettier-plugin-astro: optional: true - '@astrojs/markdown-remark@6.3.5': - resolution: {integrity: sha512-MiR92CkE2BcyWf3b86cBBw/1dKiOH0qhLgXH2OXA6cScrrmmks1Rr4Tl0p/lFpvmgQQrP54Pd1uidJfmxGrpWQ==} - '@astrojs/markdown-remark@6.3.6': resolution: {integrity: sha512-bwylYktCTsLMVoCOEHbn2GSUA3c5KT/qilekBKA3CBng0bo1TYjNZPr761vxumRk9kJGqTOtU+fgCAp5Vwokug==} @@ -271,8 +264,8 @@ packages: '@astrojs/sitemap@3.3.0': resolution: {integrity: sha512-nYE4lKQtk+Kbrw/w0G0TTgT724co0jUsU4tPlHY9au5HmTBKbwiCLwO/15b1/y13aZ4Kr9ZbMeMHlXuwn0ty4Q==} - '@astrojs/starlight@0.35.3': - resolution: {integrity: sha512-z9MbODjZl/STU3PPU18iOTkLObJBw7PA8xMe5s+KPscQGL0LNZyQUYeClG+F1/em/k+2AsokGpVPta+aOTk1sg==} + '@astrojs/starlight@0.36.0': + resolution: {integrity: sha512-aVJVBfvFuE2avsMDhmRzn6I5GjDhUwIQFlu3qH9a1C0fNsPYDw2asxHQODAD7EfGiKGvvHCJgHb+9jbJ8lCfNQ==} peerDependencies: astro: ^5.5.0 @@ -2045,6 +2038,10 @@ packages: ansi-align@3.0.1: resolution: {integrity: sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==} + ansi-escapes@7.1.1: + resolution: {integrity: sha512-Zhl0ErHcSRUaVfGUeUdDuLgpkEo8KIFjB4Y9uAc46ScOpdDiU1Dbyplh7qWJeJ/ZHpbyMSM26+X3BySgnIz40Q==} + engines: {node: '>=18'} + ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} @@ -2954,6 +2951,10 @@ packages: resolution: {integrity: sha512-dtJUTepzMW3Lm/NPxRf3wP4642UWhjL2sQxc+ym2YMj1m/H2zDNQOlezafzkHwn6sMstjHTwG6iQQsctDW/b1A==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + environment@1.1.0: + resolution: {integrity: sha512-xUtoPkMggbz0MPyPiIWr1Kp4aeWJjDZ6SMvURhimjdZgsRuDplF5/s9hcgGhyXMhs+6vpnuoiZ2kFiu3FMnS8Q==} + engines: {node: '>=18'} + error-ex@1.3.2: resolution: {integrity: sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==} @@ -3336,6 +3337,10 @@ packages: resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} engines: {node: '>=8'} + has-flag@5.0.1: + resolution: {integrity: sha512-CsNUt5x9LUdx6hnk/E2SZLsDyvfqANZSUq4+D3D8RzDJ2M+HDTIkF60ibS1vHaK55vzgiZw1bEPFG9yH7l33wA==} + engines: {node: '>=12'} + has-property-descriptors@1.0.2: resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} @@ -5078,20 +5083,20 @@ packages: stack-trace@0.0.10: resolution: {integrity: sha512-KGzahc7puUKkzyMt+IqAep+TVNbKP+k2Lmwhub39m1AsTSkaDutx56aDCo+HLDzf/D26BIHTJWNiTG1KAJiQCg==} - starlight-blog@0.24.1: - resolution: {integrity: sha512-zq4iSl6uXGC352MFjg4G1webPEfdeB4zH1z5sphNo5K5qFvcw/j0NkoR5YWFg7ubIQVasiktjyaSoBs1k8FeiA==} + starlight-blog@0.24.2: + resolution: {integrity: sha512-3DbT20GnXSUKQPSD6ijAIbbBBnAvEVcyhH0nsv/DSNhh6Jh1eb/whPA9R7KyM28s0YTeyAk4gJ0iGbb7B/uJFA==} engines: {node: '>=18.20.8'} peerDependencies: '@astrojs/starlight': '>=0.33.0' - starlight-changelogs@0.2.2: - resolution: {integrity: sha512-p29SzStrTtR4bi2AyeJyrO2jeasDzp9CRgosPRCD36yM+7jdDAqOhZTnh7tHJUWsrS23CN3hdGQ/8Tmw8gZjnA==} + starlight-changelogs@0.2.1: + resolution: {integrity: sha512-fy76e1bDicxHO/AkcqVqkkHnIMuXlWNvUops0ypF6gGErIZaHR0QHDrYrETJbUFIQCF5M6l6OD7NUl3VRGJBEw==} engines: {node: '>=18.17.1'} peerDependencies: '@astrojs/starlight': '>=0.35.0' - starlight-links-validator@0.17.2: - resolution: {integrity: sha512-d2SRWu04HPiUzrzntuv/uzuXnIu4reJwzX1c+7uvcnqOCuzgpv+tmlUC+dp3VYpmfxQy8RX+xcWtfcEkx905VA==} + starlight-links-validator@0.18.0: + resolution: {integrity: sha512-R0gLdrKWdpAEqux3DL2B3QvNJM8Zpys8CQu1BGLD9hc+66nt/Q6aJDkvvkvoCVky9JKmBEnmL4PhFkyz13lK5g==} engines: {node: '>=18.17.1'} peerDependencies: '@astrojs/starlight': '>=0.32.0' @@ -5170,10 +5175,18 @@ packages: peerDependencies: postcss: ^8.3.3 + supports-color@10.2.2: + resolution: {integrity: sha512-SS+jx45GF1QjgEXQx4NJZV9ImqmO2NPz5FNsIHrsDjh2YsHnawpan7SNQ1o8NuhrbHZy9AZhIoCUiCeaW/C80g==} + engines: {node: '>=18'} + supports-color@7.2.0: resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} engines: {node: '>=8'} + supports-hyperlinks@4.3.0: + resolution: {integrity: sha512-i6sWEzuwadSlcr2mOnb0ktlIl+K5FVxsPXmoPfknDd2gyw4ZBIAZ5coc0NQzYqDdEYXMHy8NaY9rWwa1Q1myiQ==} + engines: {node: '>=20'} + supports-preserve-symlinks-flag@1.0.0: resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} engines: {node: '>= 0.4'} @@ -5205,6 +5218,10 @@ packages: resolution: {integrity: sha512-5S7Va8hKfV7W5U6g3aYxXmlPoZVAwUMy9AOKyF2fVuZa2UD3qZjg578OrLRt8PcNN1PleVaL/5/yYATNL0ICUw==} engines: {node: '>=18'} + terminal-link@5.0.0: + resolution: {integrity: sha512-qFAy10MTMwjzjU8U16YS4YoZD+NQLHzLssFMNqgravjbvIPNiqkGFR4yjhJfmY9R5OFU7+yHxc6y+uGHkKwLRA==} + engines: {node: '>=20'} + text-decoder@1.2.3: resolution: {integrity: sha512-3/o9z3X0X0fTupwsYvR03pJ/DjWuqqrfwBgTQzdWDiQSm9KitAyz/9WqsT2JQW7KV2m+bC2ol/zqpW37NHxLaA==} @@ -5393,6 +5410,9 @@ packages: unist-util-remove-position@5.0.0: resolution: {integrity: sha512-Hp5Kh3wLxv0PHj9m2yZhhLt58KzPtEYKQQ4yxfYFEO7EvHwzyDYnduhHnY1mDxoqr7VUwVuHXk9RXKIiYS1N8Q==} + unist-util-remove@4.0.0: + resolution: {integrity: sha512-b4gokeGId57UVRX/eVKej5gXqGlc9+trkORhFJpu9raqZkZhU0zm8Doi05+HaiBsMEIJowL+2WtQ5ItjsngPXg==} + unist-util-stringify-position@2.0.3: resolution: {integrity: sha512-3faScn5I+hy9VleOq/qNbAd6pAx7iH5jYBMS9I1HgQVijz/4mv5Bvw5iw1sC/90CODiKo81G/ps8AJrISn687g==} @@ -5876,8 +5896,6 @@ snapshots: '@astrojs/compiler@2.12.2': {} - '@astrojs/internal-helpers@0.7.1': {} - '@astrojs/internal-helpers@0.7.2': {} '@astrojs/internal-helpers@0.7.4': {} @@ -5907,32 +5925,6 @@ snapshots: transitivePeerDependencies: - typescript - '@astrojs/markdown-remark@6.3.5': - dependencies: - '@astrojs/internal-helpers': 0.7.1 - '@astrojs/prism': 3.3.0 - github-slugger: 2.0.0 - hast-util-from-html: 2.0.3 - hast-util-to-text: 4.0.2 - import-meta-resolve: 4.1.0 - js-yaml: 4.1.0 - mdast-util-definitions: 6.0.0 - rehype-raw: 7.0.0 - rehype-stringify: 10.0.1 - remark-gfm: 4.0.1 - remark-parse: 11.0.0 - remark-rehype: 11.1.2 - remark-smartypants: 3.0.2 - shiki: 3.9.2 - smol-toml: 1.4.1 - unified: 11.0.5 - unist-util-remove-position: 5.0.0 - unist-util-visit: 5.0.0 - unist-util-visit-parents: 6.0.1 - vfile: 6.0.3 - transitivePeerDependencies: - - supports-color - '@astrojs/markdown-remark@6.3.6': dependencies: '@astrojs/internal-helpers': 0.7.2 @@ -6089,7 +6081,7 @@ snapshots: stream-replace-string: 2.0.0 zod: 3.25.76 - '@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))': + '@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))': dependencies: '@astrojs/markdown-remark': 6.3.6 '@astrojs/mdx': 4.3.7(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) @@ -6934,9 +6926,9 @@ snapshots: transitivePeerDependencies: - supports-color - '@lunariajs/starlight@0.1.1(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))': + '@lunariajs/starlight@0.1.1(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))': dependencies: - '@astrojs/starlight': 0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + '@astrojs/starlight': 0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) '@lunariajs/core': 0.1.1 astro: 5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0) transitivePeerDependencies: @@ -8240,6 +8232,10 @@ snapshots: dependencies: string-width: 4.2.3 + ansi-escapes@7.1.1: + dependencies: + environment: 1.1.0 + ansi-regex@5.0.1: {} ansi-regex@6.0.1: {} @@ -9259,6 +9255,8 @@ snapshots: env-paths@3.0.0: {} + environment@1.1.0: {} + error-ex@1.3.2: dependencies: is-arrayish: 0.2.1 @@ -9720,6 +9718,8 @@ snapshots: has-flag@4.0.0: {} + has-flag@5.0.1: {} + has-property-descriptors@1.0.2: dependencies: es-define-property: 1.0.1 @@ -12138,27 +12138,31 @@ snapshots: stack-trace@0.0.10: {} - starlight-blog@0.24.1(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)): + starlight-blog@0.24.2(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)): dependencies: - '@astrojs/markdown-remark': 6.3.5 + '@astrojs/markdown-remark': 6.3.6 '@astrojs/mdx': 4.3.7(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) '@astrojs/rss': 4.0.12 - '@astrojs/starlight': 0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + '@astrojs/starlight': 0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) astro-remote: 0.3.3 github-slugger: 2.0.0 + hast-util-from-html: 2.0.3 + hast-util-to-html: 9.0.5 + hast-util-to-string: 3.0.1 marked: 15.0.12 marked-plaintify: 1.1.1(marked@15.0.12) mdast-util-mdx-expression: 2.0.1 - ultrahtml: 1.6.0 + unist-util-is: 6.0.0 + unist-util-remove: 4.0.0 unist-util-visit: 5.0.0 transitivePeerDependencies: - astro - supports-color - starlight-changelogs@0.2.2(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)): + starlight-changelogs@0.2.1(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)))(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)): dependencies: '@ascorbic/loader-utils': 1.0.2(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) - '@astrojs/starlight': 0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + '@astrojs/starlight': 0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) github-slugger: 2.0.0 mdast-util-from-markdown: 2.0.2 mdast-util-to-markdown: 2.1.2 @@ -12168,9 +12172,9 @@ snapshots: - astro - supports-color - starlight-links-validator@0.17.2(@astrojs/starlight@0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))): + starlight-links-validator@0.18.0(@astrojs/starlight@0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0))): dependencies: - '@astrojs/starlight': 0.35.3(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) + '@astrojs/starlight': 0.36.0(astro@5.14.4(@netlify/blobs@10.1.0)(@types/node@22.18.10)(jiti@2.4.2)(rollup@4.40.1)(sass@1.77.8)(sugarss@5.0.0(postcss@8.5.6))(typescript@5.9.3)(yaml@2.8.0)) '@types/picomatch': 3.0.2 github-slugger: 2.0.0 hast-util-from-html: 2.0.3 @@ -12179,7 +12183,8 @@ snapshots: kleur: 4.1.5 mdast-util-mdx-jsx: 3.2.0 mdast-util-to-string: 4.0.0 - picomatch: 4.0.2 + picomatch: 4.0.3 + terminal-link: 5.0.0 unist-util-visit: 5.0.0 transitivePeerDependencies: - supports-color @@ -12262,10 +12267,17 @@ snapshots: dependencies: postcss: 8.5.6 + supports-color@10.2.2: {} + supports-color@7.2.0: dependencies: has-flag: 4.0.0 + supports-hyperlinks@4.3.0: + dependencies: + has-flag: 5.0.1 + supports-color: 10.2.2 + supports-preserve-symlinks-flag@1.0.0: {} svelte@4.2.19: @@ -12322,6 +12334,11 @@ snapshots: mkdirp: 3.0.1 yallist: 5.0.0 + terminal-link@5.0.0: + dependencies: + ansi-escapes: 7.1.1 + supports-hyperlinks: 4.3.0 + text-decoder@1.2.3: dependencies: b4a: 1.6.7 @@ -12539,6 +12556,12 @@ snapshots: '@types/unist': 3.0.2 unist-util-visit: 5.0.0 + unist-util-remove@4.0.0: + dependencies: + '@types/unist': 3.0.2 + unist-util-is: 6.0.0 + unist-util-visit-parents: 6.0.1 + unist-util-stringify-position@2.0.3: dependencies: '@types/unist': 2.0.10 diff --git a/src/content/docs/internals/language-support.mdx b/src/content/docs/internals/language-support.mdx index 95211fe08..8067459a1 100644 --- a/src/content/docs/internals/language-support.mdx +++ b/src/content/docs/internals/language-support.mdx @@ -7,25 +7,25 @@ Legend: - ✅: Supported - 🚫: Not in progress - ⌛️: In progress -- ⚠️: Partially supported (with some caveats) - -| Language | Parsing | Formatting | Linting | Plugin Support | -|----------------------------------------------------------|-------------------------------------------------------------|-------------------------------------------------------------|-------------------------------------------------------------|---------------------------------------------------------| -| [JavaScript](#javascript-support) | | | | | -| [TypeScript](#typescript-support) | | | | | -| JSX | | | | | -| TSX | | | | | -| JSON | | | | 🚫 | -| JSONC | | | | 🚫 | -| HTML | | | | 🚫 | -| [Vue](#html-super-languages-support) | ⚠️ | ⚠️ | ⚠️ | 🚫 | -| [Svelte](#html-super-languages-support) | ⚠️ | ⚠️ | ⚠️ | 🚫 | -| [Astro](#html-super-languages-support) | ⚠️ | ⚠️ | ⚠️ | 🚫 | -| CSS | ✅️ | ✅️ | ✅️ | | -| [YAML](https://github.com/biomejs/biome/issues/2365) | ⌛️ | 🚫 | 🚫 | 🚫 | -| GraphQL | ✅️ | ✅️ | ✅️ | 🚫 | -| [Markdown](https://github.com/biomejs/biome/issues/3718) | ⌛️ | 🚫 | 🚫 | 🚫 | -| GritQL | ✅️ | ✅️ | 🚫 | 🚫 | +- 🟡: Experimental + +| Language | Parsing | Formatting | Linting | Plugin Support | +|----------------------------------------------------------|------------------------------------------------------|---------------------------------------------------------|---------------------------------------------------------|---------------------------------------------------------| +| [JavaScript](#javascript-support) | | | | | +| [TypeScript](#typescript-support) | | | | | +| JSX | | | | | +| TSX | | | | | +| JSON | | | | 🚫 | +| JSONC | | | | 🚫 | +| HTML | | | | 🚫 | +| [Vue](#html-super-languages-support) | 🟡 | | | 🚫 | +| [Svelte](#html-super-languages-support) | 🟡 | | | 🚫 | +| [Astro](#html-super-languages-support) | 🟡 | | | 🚫 | +| CSS | ✅️ | ✅️ | ✅️ | | +| [YAML](https://github.com/biomejs/biome/issues/2365) | ⌛️ | 🚫 | 🚫 | 🚫 | +| GraphQL | ✅️ | ✅️ | ✅️ | 🚫 | +| [Markdown](https://github.com/biomejs/biome/issues/3718) | ⌛️ | 🚫 | 🚫 | 🚫 | +| GritQL | ✅️ | ✅️ | 🚫 | 🚫 | ## JavaScript support @@ -54,39 +54,36 @@ Please note, some well-known files like `tsconfig.json` and `.babelrc` don't use ## HTML super languages support -As of version `1.6.0`, these languages are **partially** supported. Biome will get better over time, and it will provide more options to tweak your project. As for today, there are some expectations and limitations to take in consideration: -- For `.astro` files, **only** the **frontmatter** portion of the file is supported. -- For `.vue` and `.svelte` files, **only** the **\** tags portion of the file is supported. -- Diagnostics will only show code frames that belong to the portions mentioned above. -- When **formatting** `.vue` and `.svelte` files, the indentation of the JavaScript/TypeScript code will start from the beginning. - - ```vue title="file.vue" del={2} ins={3} - - ``` - -- When **linting** `.svelte`, `.astro` or `.vue` files, it's advised to turn off a few additional rules to prevent false positive linting errors caused by our partial support. Use the option `overrides` for that: - - ```json - { - "overrides": [ - { - "includes": ["**/*.svelte", "**/*.astro", "**/*.vue"], - "linter": { - "rules": { - "style": { - "useConst": "off", - "useImportType": "off" - }, - "correctness": { - "noUnusedVariables": "off", - "noUnusedImports": "off" - } +Since version `v2.5.0`, Biome supports Vue, Svelte and Astro file out of the box. This means that Biome is able to format and lint the HTML, CSS and JavaScript parts of the files. + +However, this **support must be considered experimental** and subject to changes and improvements. In `v2.5.0`, we landed the architecture that enables this feature, however some formatting and linting rules must be adjusted. + +In particular, as for `v2.5.0`, Biome doesn't do any particular parsing for language specific syntax, for example the control-flow syntax of Svelte e.g. `{#if } {/if}`. This means that formatting might not match the desired expectations, and lint rules might not detect some cases. + +When **linting** `.svelte`, `.astro` or `.vue` files, it's advised to turn off a few additional rules to prevent false positive linting errors caused by our partial support. Use the option `overrides` for that: + +```json +{ + "overrides": [ + { + "includes": ["**/*.svelte", "**/*.astro", "**/*.vue"], + "linter": { + "rules": { + "style": { + "useConst": "off", + "useImportType": "off" + }, + "correctness": { + "noUnusedVariables": "off", + "noUnusedImports": "off" } } } - ] - } - ``` + } + ] +} +``` + +:::note +This last section might become outdated, so it's advised to use the [playground](https://biomejs.dev/playground), and check if your feature has been implemented. +::: diff --git a/src/content/docs/reference/configuration.mdx b/src/content/docs/reference/configuration.mdx index f641ef388..10d075477 100644 --- a/src/content/docs/reference/configuration.mdx +++ b/src/content/docs/reference/configuration.mdx @@ -1333,8 +1333,9 @@ Enables Biome's assist for Grit files. ## `html` :::caution -The HTML parser and formatter are still considered experimental, which means that breaking changes -can happen in patch and minor versions. +While HTML parser, formatter and linter are enabled by default, they are still considered experimental. +Breaking changes will be reduced to a minimum, however the introduction of fixes and features might change +the behavior of the tools. ::: ### `html.parser.interpolation` @@ -1347,7 +1348,7 @@ Enables the parsing of double text expressions such as `{{ expression }}` inside Enables Biome's formatter for HTML files. -> Default: `false` +> Default: `true` ### `html.formatter.indentStyle` @@ -1441,13 +1442,13 @@ Whether void elements should be self-closed. Defaults to never. Enables Biome's linter for HTML files. -> Default: `false` +> Default: `true` ### `html.linter.assist` Enables Biome's assist for HTML files. -> Default: `false` +> Default: `true` ## `overrides` From b4300ebc39ebc66ae7568cd43e8adacfd468d6ba Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Mon, 13 Oct 2025 10:48:02 +0100 Subject: [PATCH 2/6] feedback --- src/content/docs/internals/language-support.mdx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/content/docs/internals/language-support.mdx b/src/content/docs/internals/language-support.mdx index 8067459a1..73848f262 100644 --- a/src/content/docs/internals/language-support.mdx +++ b/src/content/docs/internals/language-support.mdx @@ -17,10 +17,10 @@ Legend: | TSX | | | | | | JSON | | | | 🚫 | | JSONC | | | | 🚫 | -| HTML | | | | 🚫 | -| [Vue](#html-super-languages-support) | 🟡 | | | 🚫 | -| [Svelte](#html-super-languages-support) | 🟡 | | | 🚫 | -| [Astro](#html-super-languages-support) | 🟡 | | | 🚫 | +| HTML | | | | | +| [Vue](#html-super-languages-support) | 🟡 | 🟡 | 🟡 | 🟡 | +| [Svelte](#html-super-languages-support) | 🟡 | 🟡 | 🟡 | 🟡 | +| [Astro](#html-super-languages-support) | 🟡 | 🟡 | 🟡 | 🟡 | | CSS | ✅️ | ✅️ | ✅️ | | | [YAML](https://github.com/biomejs/biome/issues/2365) | ⌛️ | 🚫 | 🚫 | 🚫 | | GraphQL | ✅️ | ✅️ | ✅️ | 🚫 | @@ -60,6 +60,8 @@ However, this **support must be considered experimental** and subject to changes In particular, as for `v2.5.0`, Biome doesn't do any particular parsing for language specific syntax, for example the control-flow syntax of Svelte e.g. `{#if } {/if}`. This means that formatting might not match the desired expectations, and lint rules might not detect some cases. +Lint rules that work across embedded languages aren't supported yet. + When **linting** `.svelte`, `.astro` or `.vue` files, it's advised to turn off a few additional rules to prevent false positive linting errors caused by our partial support. Use the option `overrides` for that: ```json From 44848d024886ca86a795258fb398a28d3480a795 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Mon, 13 Oct 2025 11:18:34 +0100 Subject: [PATCH 3/6] fix types --- src/playground/workers/biomeWorker.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/playground/workers/biomeWorker.ts b/src/playground/workers/biomeWorker.ts index e36cc71c8..50009b05c 100644 --- a/src/playground/workers/biomeWorker.ts +++ b/src/playground/workers/biomeWorker.ts @@ -1,10 +1,10 @@ import init, { + type AnalyzerSelector, type Configuration, DiagnosticPrinter, MemoryFileSystem, type ProjectKey, type RuleCategories, - type RuleCode, Workspace, } from "@biomejs/wasm-web"; import { LINT_RULES } from "@/playground/generated/lintRules.ts"; @@ -30,7 +30,7 @@ let projectKey: ProjectKey | null = null; let configuration: undefined | Configuration; let fullSettings: undefined | PlaygroundSettings; -let only: RuleCode[] = []; +let only: AnalyzerSelector[] = []; // Configuration that comes from a virtual file. It takes precedence over the settings let fileConfiguration: undefined | Configuration; From f98fec75c37f0d8daa6eb9c4757f8763bfdbb3f5 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Mon, 13 Oct 2025 11:19:39 +0100 Subject: [PATCH 4/6] fix default value --- src/content/docs/reference/configuration.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/docs/reference/configuration.mdx b/src/content/docs/reference/configuration.mdx index 10d075477..a5fc2e927 100644 --- a/src/content/docs/reference/configuration.mdx +++ b/src/content/docs/reference/configuration.mdx @@ -1348,7 +1348,7 @@ Enables the parsing of double text expressions such as `{{ expression }}` inside Enables Biome's formatter for HTML files. -> Default: `true` +> Default: `false` ### `html.formatter.indentStyle` From a24f6f981b5e14b0134bf4f1d3a18ca4a2e39568 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Tue, 14 Oct 2025 11:49:25 +0100 Subject: [PATCH 5/6] update the playground --- .../docs/internals/language-support.mdx | 27 ++++++++++ src/playground/tabs/SettingsTab.tsx | 51 +++++++++++++++++++ src/playground/types.ts | 4 ++ src/playground/workers/biomeWorker.ts | 4 ++ 4 files changed, 86 insertions(+) diff --git a/src/content/docs/internals/language-support.mdx b/src/content/docs/internals/language-support.mdx index 73848f262..6c6d2bd9c 100644 --- a/src/content/docs/internals/language-support.mdx +++ b/src/content/docs/internals/language-support.mdx @@ -62,6 +62,8 @@ In particular, as for `v2.5.0`, Biome doesn't do any particular parsing for lang Lint rules that work across embedded languages aren't supported yet. +### Linting HTML-ish languages + When **linting** `.svelte`, `.astro` or `.vue` files, it's advised to turn off a few additional rules to prevent false positive linting errors caused by our partial support. Use the option `overrides` for that: ```json @@ -86,6 +88,31 @@ When **linting** `.svelte`, `.astro` or `.vue` files, it's advised to turn off a } ``` +### Formatting with different settings + +With Biome, you can control the formatting of different languages. Now that Biome can process multiple languages in the same file, +the chances of inconsistencies can grow based on your configuration. + +For example, you could risk having a file mixed with tabs and spaces when formatting a HTML-ish file that contains JavaScript and CSS code, like in the following example (we assume full support is enabled): + +```json +{ + "javascript": { + "format": { + "indentStyle": "tab" + } + }, + "css": { + "format": { + "indentStyle": "space", + "indentWidth": 4 + } + } +} +``` + +We created a [GitHub discussion](https://github.com/biomejs/biome/discussions/7754) to address the issue, join the discussion and let us know what you think. + :::note This last section might become outdated, so it's advised to use the [playground](https://biomejs.dev/playground), and check if your feature has been implemented. ::: diff --git a/src/playground/tabs/SettingsTab.tsx b/src/playground/tabs/SettingsTab.tsx index 07bc60718..1c555fb56 100644 --- a/src/playground/tabs/SettingsTab.tsx +++ b/src/playground/tabs/SettingsTab.tsx @@ -68,6 +68,8 @@ export default function SettingsTab({ allowComments, attributePosition, ruleDomains, + experimentalFullSupportEnabled, + cssModules, }, }, }: SettingsTabProps) { @@ -165,6 +167,16 @@ export default function SettingsTab({ "ruleDomains", ); + const setExperimentalFullSupportEnabled = createPlaygroundSettingsSetter( + setPlaygroundState, + "experimentalFullSupportEnabled", + ); + + const setCssModules = createPlaygroundSettingsSetter( + setPlaygroundState, + "cssModules", + ); + function setCurrentFilename(newFilename: string) { setPlaygroundState((state) => { if (state.currentFile === newFilename) { @@ -356,6 +368,10 @@ export default function SettingsTab({ setUnsafeParameterDecoratorsEnabled } setAllowComments={setAllowComments} + experimentalFullSupportEnabled={experimentalFullSupportEnabled} + setExperimentalFullSupportEnabled={setExperimentalFullSupportEnabled} + cssModules={cssModules} + setCssModules={setCssModules} /> ); @@ -579,6 +595,10 @@ function SyntaxSettings({ setUnsafeParameterDecoratorsEnabled, setAllowComments, allowComments, + experimentalFullSupportEnabled, + setExperimentalFullSupportEnabled, + cssModules, + setCssModules, }: { filename: string; setFilename: (filename: string) => void; @@ -586,11 +606,17 @@ function SyntaxSettings({ allowComments: boolean; setUnsafeParameterDecoratorsEnabled: (value: boolean) => void; setAllowComments: (value: boolean) => void; + experimentalFullSupportEnabled: boolean; + setExperimentalFullSupportEnabled: (value: boolean) => void; + cssModules: boolean; + setCssModules: (value: boolean) => void; }) { const isScript = isScriptFilename(filename); const enumSelectId = useId(); const allowCommentsId = useId(); const decoratorsId = useId(); + const experimentalFullSupportId = useId(); + const cssModulesId = useId(); return ( <>

Syntax options

@@ -638,6 +664,31 @@ function SyntaxSettings({ /> +
+ + setExperimentalFullSupportEnabled(e.target.checked) + } + /> + +
+ +
+ setCssModules(e.target.checked)} + /> + +
); diff --git a/src/playground/types.ts b/src/playground/types.ts index a2e01bb93..d01ebbdad 100644 --- a/src/playground/types.ts +++ b/src/playground/types.ts @@ -183,6 +183,8 @@ export interface PlaygroundSettings { ruleDomains: RuleDomains; indentScriptAndStyle: boolean; whitespaceSensitivity: WhitespaceSensitivity; + experimentalFullSupportEnabled: boolean; + cssModules: boolean; } export interface PlaygroundFileState { @@ -235,6 +237,8 @@ export const defaultPlaygroundState: PlaygroundState = { ruleDomains: {}, indentScriptAndStyle: false, whitespaceSensitivity: WhitespaceSensitivity.Css, + experimentalFullSupportEnabled: true, + cssModules: false, }, }; diff --git a/src/playground/workers/biomeWorker.ts b/src/playground/workers/biomeWorker.ts index 50009b05c..8b016eb9d 100644 --- a/src/playground/workers/biomeWorker.ts +++ b/src/playground/workers/biomeWorker.ts @@ -93,6 +93,8 @@ self.addEventListener("message", async (e) => { allowComments, attributePosition, ruleDomains, + experimentalFullSupportEnabled, + cssModules, } = e.data.settings as PlaygroundSettings; configuration = { @@ -156,6 +158,7 @@ self.addEventListener("message", async (e) => { }, parser: { allowWrongLineComments: true, + cssModules, }, }, json: { @@ -169,6 +172,7 @@ self.addEventListener("message", async (e) => { indentScriptAndStyle, whitespaceSensitivity, }, + experimentalFullSupportEnabled, }, }; From 35068cc13e99f8cecd750aa704a4371865e3e034 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Wed, 15 Oct 2025 08:37:07 +0100 Subject: [PATCH 6/6] fix types --- src/playground/PlaygroundLoader.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/playground/PlaygroundLoader.tsx b/src/playground/PlaygroundLoader.tsx index 185882966..b80f0e093 100644 --- a/src/playground/PlaygroundLoader.tsx +++ b/src/playground/PlaygroundLoader.tsx @@ -414,6 +414,12 @@ function initState( searchParams.get("allowComments") === "true" || defaultPlaygroundState.settings.allowComments, ruleDomains, + cssModules: + searchParams.get("cssModules") === "true" || + defaultPlaygroundState.settings.cssModules, + experimentalFullSupportEnabled: + searchParams.get("experimentalFullSupportEnabled") === "true" || + defaultPlaygroundState.settings.experimentalFullSupportEnabled, }, }; }