docs: fix conflicting info regarding HTML and clarify#3829
Conversation
✅ Deploy Preview for biomejs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
WalkthroughThis change clarifies HTML configuration: the HTML formatter is explicitly disabled by default while experimental. Suggested reviewers
🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Fix all issues with AI agents
In `@src/content/docs/reference/configuration.mdx`:
- Around line 1352-1353: Replace the non-canonical casing
"Javascript/Typescript" in the documentation text with the correct
"JavaScript/TypeScript" (look for the exact string "Javascript/Typescript" in
the sentence starting "When disabled, Biome will only extract the
Javascript/Typescript parts...") so the doc uses the standard capitalisation for
both names.
- Around line 1341-1357: Update the caution block text to accurately state that
only the HTML parser and formatter are disabled by default (not the linter);
change the sentence that currently reads "The HTML parser, formatter and linter
are **disabled** by default" to mention only "parser and formatter" and
optionally note that html.linter.enabled and html.assist.enabled default to
true; also correct the wording "Javascript/Typescript" to
"JavaScript/TypeScript" in the description of
html.experimentalFullSupportEnabled and ensure the note about enabling
html.formatter.enabled remains intact.
| :::caution | ||
| While HTML parser, formatter and linter are enabled by default, they are still considered experimental. | ||
| The HTML parser, formatter and linter are **disabled** by default because it is still experimental. | ||
| Breaking changes will be reduced to a minimum, however the introduction of fixes and features might change | ||
| the behavior of the tools. | ||
| ::: | ||
|
|
||
| ### `html.experimentalFullSupportEnabled` | ||
|
|
||
| When enabled, Biome enables full support for HTML-ish languages. Parsing, formatting and linting of | ||
| When enabled, Biome enables full support for HTML-ish languages (Vue, Svelte, and Astro files). Parsing, formatting and linting of | ||
| embedded languages inside these files are consistent. | ||
|
|
||
| When disabled, Biome will only extract the Javascript/Typescript parts of these files for analysis, while ignoring the rest of the content. | ||
|
|
||
| :::note | ||
| Enabling this option merely switches this behavior for these files, not plain `.html` files. To format HTML files, you also | ||
| need to enable `html.formatter.enabled`. | ||
| ::: |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
python - <<'PY'
import json, urllib.request
try:
url = "https://biomejs.dev/schemas/2.3.11/schema.json"
data = json.load(urllib.request.urlopen(url))
def walk(node, path):
if isinstance(node, dict):
if "default" in node and "html" in path:
print(".".join(path), "=", node["default"])
for k, v in node.items():
walk(v, path + [k])
elif isinstance(node, list):
for i, v in enumerate(node):
walk(v, path + [str(i)])
walk(data, [])
except Exception as e:
print(f"Error fetching schema: {e}")
PYRepository: biomejs/website
Length of output: 145
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Search for html configuration defaults in the repository
echo "=== Searching for html configuration defaults ==="
rg "html\.(linter|formatter|assist)\.enabled" --max-count 20 -B 2 -A 2
echo ""
echo "=== Searching for 'default' near html configuration ==="
rg "html\." src/content/docs/reference/configuration.mdx | head -30
echo ""
echo "=== Checking if there's a defaults section in configuration.mdx ==="
rg -A 5 -B 5 "default.*true|default.*false" src/content/docs/reference/configuration.mdx | grep -i html | head -40Repository: biomejs/website
Length of output: 3571
🏁 Script executed:
#!/bin/bash
rg "html\.parser\.enabled" src/content/docs/reference/configuration.mdx -A 3 -B 3Repository: biomejs/website
Length of output: 41
🏁 Script executed:
#!/bin/bash
sed -n '1330,1380p' src/content/docs/reference/configuration.mdxRepository: biomejs/website
Length of output: 1410
🏁 Script executed:
#!/bin/bash
sed -n '1360,1375p' src/content/docs/reference/configuration.mdxRepository: biomejs/website
Length of output: 398
🏁 Script executed:
#!/bin/bash
grep -n "html.linter.enabled" src/content/docs/reference/configuration.mdx -A 3Repository: biomejs/website
Length of output: 145
🏁 Script executed:
#!/bin/bash
sed -n '1469,1480p' src/content/docs/reference/configuration.mdxRepository: biomejs/website
Length of output: 230
The caution overstates what's disabled by default—the linter is actually enabled.
The caution claims the HTML parser, formatter, and linter are disabled by default, but html.linter.enabled has a default of true (as does html.assist.enabled). Update the caution to reflect that only the parser and formatter are disabled by default.
Minor fix: "Javascript/Typescript" (line 1352) should be "JavaScript/TypeScript".
🤖 Prompt for AI Agents
In `@src/content/docs/reference/configuration.mdx` around lines 1341 - 1357,
Update the caution block text to accurately state that only the HTML parser and
formatter are disabled by default (not the linter); change the sentence that
currently reads "The HTML parser, formatter and linter are **disabled** by
default" to mention only "parser and formatter" and optionally note that
html.linter.enabled and html.assist.enabled default to true; also correct the
wording "Javascript/Typescript" to "JavaScript/TypeScript" in the description of
html.experimentalFullSupportEnabled and ensure the note about enabling
html.formatter.enabled remains intact.
77bf275 to
a68840e
Compare
9d7958d to
e751c45
Compare
e751c45 to
d949879
Compare
Summary
fixes #3828