Skip to content

Commit b46bc2c

Browse files
fix(deps-dev): bump prettier-plugin-astro from 0.14.1 to 1.0.0 (#361)
Bumps [prettier-plugin-astro](https://github.com/withastro/prettier-plugin-astro) from 0.14.1 to 1.0.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/withastro/prettier-plugin-astro/releases">prettier-plugin-astro's releases</a>.</em></p> <blockquote> <h2>v1.0.0</h2> <h3>Major Changes</h3> <ul> <li> <p>a8bf1a3: Raises the minimum supported Node version to 22.12.0.</p> </li> <li> <p>595d47f: The plugin has been fully rewritten on top of Astro 7's new Rust compiler. This rewrite fixes many long-standing issues, such as certain elements not being handled properly inside expressions.</p> <p>Whitespace formatting now matches Astro’s whitespace handling, and a new <code>astroCompressHTML</code> option has been added to match Astro's <a href="https://docs.astro.build/en/reference/configuration-reference/#compresshtml"><code>compressHTML</code></a> setting. If you set <code>compressHTML</code> in your Astro config, also set <code>astroCompressHTML</code> in your Prettier config to match.</p> <p>In addition, this rewrite has allowed us to more closely match Prettier's built-in JSX and HTML formatting, leading to less cosmetic differences between the different files in your repo.</p> </li> </ul> <h2>v1.0.0-beta.2</h2> <h3>Patch Changes</h3> <ul> <li> <p>cc30d24: Fixes various formatting issues when using <code>astroCompressHTML: 'html'</code> or <code>'none'</code>:</p> <ul> <li>Fixes a stray <code>&gt;</code> being added after an empty or ignored element that is followed by a sibling.</li> <li>Fixes closing tags being split from trailing void elements like <code>&lt;img&gt;</code>.</li> <li>Fixes whitespace being added inside tables, lists, and captions under <code>htmlWhitespaceSensitivity: 'strict'</code>.</li> <li>Fixes line breaks around inline elements being replaced by spaces.</li> <li>Allows inline elements to wrap at the print width without adding rendered whitespace.</li> <li>Keeps inline elements written on one line on that line.</li> <li>Fixes components with dotted names like <code>&lt;Astro.self&gt;</code> losing their closing tags or failing to format.</li> <li>Fixes whitespace around <code>inline-block</code> elements and reflowing markup written on one line.</li> <li>Fixes quotes in <code>style</code> attribute values being written unescaped, corrupting the attribute and breaking the next format.</li> <li>Fixes children hugging the closing bracket when an element's attributes span multiple lines.</li> <li>Fixes whitespace being added around a lone <code>&lt;slot /&gt;</code>, which stopped <code>:empty</code> from matching the container.</li> <li>Fixes <code>srcset</code> values being mangled when a URL contains a comma, such as a <code>data:</code> URI or query string.</li> <li>Lays out block-level elements like HTML.</li> <li>Fixes whitespace being removed around a lone <code>&lt;slot /&gt;</code>, which allowed <code>:empty</code> to start matching the container.</li> <li>Fixes children hugging the closing bracket when an element's attributes wrap and allows a lone long attribute to wrap.</li> <li>Formats <code>style</code> and <code>srcset</code> attributes.</li> <li>Allows runs of adjacent inline elements to wrap at the print width without adding rendered whitespace.</li> <li>Lays out graphical SVG contents one element per line.</li> <li>Fixes nested markup being kept on one line.</li> <li>Fixes spaces being removed from text directly inside <code>&lt;body&gt;</code>.</li> <li>Fixes nested elements being collapsed onto a single line.</li> <li>Fixes a blank line being left inside an opening tag whose attributes break.</li> </ul> </li> </ul> <h2>v1.0.0-beta.1</h2> <h3>Major Changes</h3> <ul> <li>a8bf1a3: Raises the minimum supported Node version to 22.12.0.</li> </ul> <h3>Patch Changes</h3> <ul> <li>b0ec799: Fixes <code>&lt;script&gt;</code> tags being formatted as JavaScript instead of TypeScript</li> <li>04ecfe2: Fixes a crash on parenthesized types in template expressions</li> </ul> <h2>v1.0.0-beta.0</h2> <h3>Major Changes</h3> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/withastro/prettier-plugin-astro/blob/main/CHANGELOG.md">prettier-plugin-astro's changelog</a>.</em></p> <blockquote> <h2>1.0.0</h2> <h3>Major Changes</h3> <ul> <li> <p>a8bf1a3: Raises the minimum supported Node version to 22.12.0.</p> </li> <li> <p>595d47f: The plugin has been fully rewritten on top of Astro 7's new Rust compiler. This rewrite fixes many long-standing issues, such as certain elements not being handled properly inside expressions.</p> <p>Whitespace formatting now matches Astro’s whitespace handling, and a new <code>astroCompressHTML</code> option has been added to match Astro's <a href="https://docs.astro.build/en/reference/configuration-reference/#compresshtml"><code>compressHTML</code></a> setting. If you set <code>compressHTML</code> in your Astro config, also set <code>astroCompressHTML</code> in your Prettier config to match.</p> <p>In addition, this rewrite has allowed us to more closely match Prettier's built-in JSX and HTML formatting, leading to less cosmetic differences between the different files in your repo.</p> </li> </ul> <h2>1.0.0-beta.2</h2> <h3>Patch Changes</h3> <ul> <li> <p>cc30d24: Fixes various formatting issues when using <code>astroCompressHTML: 'html'</code> or <code>'none'</code>:</p> <ul> <li>Fixes a stray <code>&gt;</code> being added after an empty or ignored element that is followed by a sibling.</li> <li>Fixes closing tags being split from trailing void elements like <code>&lt;img&gt;</code>.</li> <li>Fixes whitespace being added inside tables, lists, and captions under <code>htmlWhitespaceSensitivity: 'strict'</code>.</li> <li>Fixes line breaks around inline elements being replaced by spaces.</li> <li>Allows inline elements to wrap at the print width without adding rendered whitespace.</li> <li>Keeps inline elements written on one line on that line.</li> <li>Fixes components with dotted names like <code>&lt;Astro.self&gt;</code> losing their closing tags or failing to format.</li> <li>Fixes whitespace around <code>inline-block</code> elements and reflowing markup written on one line.</li> <li>Fixes quotes in <code>style</code> attribute values being written unescaped, corrupting the attribute and breaking the next format.</li> <li>Fixes children hugging the closing bracket when an element's attributes span multiple lines.</li> <li>Fixes whitespace being added around a lone <code>&lt;slot /&gt;</code>, which stopped <code>:empty</code> from matching the container.</li> <li>Fixes <code>srcset</code> values being mangled when a URL contains a comma, such as a <code>data:</code> URI or query string.</li> <li>Lays out block-level elements like HTML.</li> <li>Fixes whitespace being removed around a lone <code>&lt;slot /&gt;</code>, which allowed <code>:empty</code> to start matching the container.</li> <li>Fixes children hugging the closing bracket when an element's attributes wrap and allows a lone long attribute to wrap.</li> <li>Formats <code>style</code> and <code>srcset</code> attributes.</li> <li>Allows runs of adjacent inline elements to wrap at the print width without adding rendered whitespace.</li> <li>Lays out graphical SVG contents one element per line.</li> <li>Fixes nested markup being kept on one line.</li> <li>Fixes spaces being removed from text directly inside <code>&lt;body&gt;</code>.</li> <li>Fixes nested elements being collapsed onto a single line.</li> <li>Fixes a blank line being left inside an opening tag whose attributes break.</li> </ul> </li> </ul> <h2>1.0.0-beta.1</h2> <h3>Major Changes</h3> <ul> <li>a8bf1a3: Raises the minimum supported Node version to 22.12.0.</li> </ul> <h3>Patch Changes</h3> <ul> <li>b0ec799: Fixes <code>&lt;script&gt;</code> tags being formatted as JavaScript instead of TypeScript</li> <li>04ecfe2: Fixes a crash on parenthesized types in template expressions</li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/4632d1bb67d55b607a6cb940a71d647bf9a6a88f"><code>4632d1b</code></a> Version Packages (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/478">#478</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/9d76a479791bd1cacf5e2b855c5c4e46626d4402"><code>9d76a47</code></a> feat: clean up changesets before 1.0 (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/480">#480</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/16c455c0bae62de635db378d34a9084d40592eb3"><code>16c455c</code></a> [ci] format</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/584f73dea3de1f201980f65a0a921c8094903544"><code>584f73d</code></a> fix: preserve styles in compressed HTML modes (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/479">#479</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/be1a35c203cca3ca9ce3ee73180210118cddf836"><code>be1a35c</code></a> chore: exit changeset pre mode (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/477">#477</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/2d7f419fda6fc301dc83fa891dbfb81834a0a6fb"><code>2d7f419</code></a> Version Packages (beta) (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/475">#475</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/cc30d24b74f24a06a7bfc65b0aee2de157f781d8"><code>cc30d24</code></a> fix(printer): match Prettier's HTML printer (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/474">#474</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/6cff4169a1b2e0feb76b27b9d9557f2faed4b831"><code>6cff416</code></a> Version Packages (beta) (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/473">#473</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/a8bf1a31eff7dc0cb8c9a52f43d8a896d3562852"><code>a8bf1a3</code></a> chore: bump all dependencies and modernize tooling (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/470">#470</a>)</li> <li><a href="https://github.com/withastro/prettier-plugin-astro/commit/04ecfe2427239af2af400c3e8f1dc9cc05fb6b3b"><code>04ecfe2</code></a> fix(parser): strip parenthesized type nodes from the AST (<a href="https://redirect.github.com/withastro/prettier-plugin-astro/issues/472">#472</a>)</li> <li>Additional commits viewable in <a href="https://github.com/withastro/prettier-plugin-astro/compare/v0.14.1...v1.0.0">compare view</a></li> </ul> </details> <details> <summary>Maintainer changes</summary> <p>This version was pushed to npm by <a href="https://www.npmjs.com/~GitHub%20Actions">GitHub Actions</a>, a new releaser for prettier-plugin-astro since your current version.</p> </details> <br /> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Bernardo Gurgel <brnrdog@hey.com>
1 parent 35490ba commit b46bc2c

4 files changed

Lines changed: 96 additions & 92 deletions

File tree

‎docs/pages/apidocs/index.astro‎

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,10 @@ const headings = [
1818
<StarlightPage frontmatter={frontmatter} headings={headings}>
1919
<h2 id="web-apis">Web APIs</h2>
2020
<ul>
21-
{
22-
apiModules.map(({ moduleName, link }) => (
23-
<li>
24-
<a href={`${import.meta.env.BASE_URL}/${link}`}>{moduleName}</a>
25-
</li>
26-
))
27-
}
21+
{apiModules.map(({ moduleName, link }) => (
22+
<li>
23+
<a href={`${import.meta.env.BASE_URL}/${link}`}>{moduleName}</a>
24+
</li>
25+
))}
2826
</ul>
2927
</StarlightPage>

‎docs/pages/examples.astro‎

Lines changed: 19 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -16,29 +16,26 @@ const headings = testFiles.map(({ name }) => ({
1616

1717
<StarlightPage frontmatter={frontmatter} headings={headings}>
1818
<p>
19-
The best example of usage of these bindings are the <a href="./06-testing"
20-
>tests</a
21-
>. <br />
22-
These exercise the public bindings directly. Reusable Web API bindings and conversion
23-
helpers belong in the library rather than in individual examples.
19+
The best example of usage of these bindings are the{" "}
20+
<a href="./06-testing">tests</a>. <br />
21+
These exercise the public bindings directly. Reusable Web API bindings and
22+
conversion helpers belong in the library rather than in individual examples.
2423
</p>
25-
{
26-
testFiles.map(({ source, output, name }) => {
27-
return (
28-
<div class="example" id={name}>
29-
<h2>{name}</h2>
30-
<Tabs>
31-
<TabItem label="ReScript">
32-
<Code code={source} lang="ReScript" frame="none" />
33-
</TabItem>
34-
<TabItem label="JS Output">
35-
<Code code={output} lang="js" frame="none" />
36-
</TabItem>
37-
</Tabs>
38-
</div>
39-
);
40-
})
41-
}
24+
{testFiles.map(({ source, output, name }) => {
25+
return (
26+
<div class="example" id={name}>
27+
<h2>{name}</h2>
28+
<Tabs>
29+
<TabItem label="ReScript">
30+
<Code code={source} lang="ReScript" frame="none" />
31+
</TabItem>
32+
<TabItem label="JS Output">
33+
<Code code={output} lang="js" frame="none" />
34+
</TabItem>
35+
</Tabs>
36+
</div>
37+
);
38+
})}
4239
</StarlightPage>
4340
<style>
4441
.example {

‎package-lock.json‎

Lines changed: 71 additions & 62 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
"micromark": "^4.0.1",
5252
"oxfmt": "^0.68.0",
5353
"prettier": "^3.8.3",
54-
"prettier-plugin-astro": "^0.14.1",
54+
"prettier-plugin-astro": "^1.0.0",
5555
"rescript": "^13.0.0-alpha.4",
5656
"sharp": "^0.35.3"
5757
},

0 commit comments

Comments
 (0)