58.md (10792B)
1 # PR #58 Bump astro from 4.0.6 to 4.9.2 2 3 - **Status:** closed 4 - **Author:** @dependabot[bot] 5 - **Created:** 2024-06-03T01:25:27Z 6 - **Branch:** dependabot/npm_and_yarn/astro-4.9.2 → main 7 - **Closed:** 2024-06-10T01:45:54Z 8 - **Labels:** dependencies, javascript 9 - **Diff:** [58.diff](./58.diff) 10 11 --- 12 13 Bumps [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro) from 4.0.6 to 4.9.2. 14 <details> 15 <summary>Release notes</summary> 16 <p><em>Sourced from <a href="https://github.com/withastro/astro/releases">astro's releases</a>.</em></p> 17 <blockquote> 18 <h2>astro@4.9.2</h2> 19 <h3>Patch Changes</h3> 20 <ul> 21 <li> 22 <p><a href="https://redirect.github.com/withastro/astro/pull/11138">#11138</a> <a href="https://github.com/withastro/astro/commit/98e0372cfd47a3e025be2ac68d1e9ebf06cf548b"><code>98e0372</code></a> Thanks <a href="https://github.com/ematipico"><code>@ematipico</code></a>! - You can now pass <code>props</code> when rendering a component using the Container APIs:</p> 23 <pre lang="js"><code>import { experimental_AstroContainer as AstroContainer } from 'astro/contaienr'; 24 import Card from '../src/components/Card.astro'; 25 <p>const container = await AstroContainer.create(); 26 const result = await container.renderToString(Card, { 27 props: { 28 someState: true, 29 }, 30 }); 31 </code></pre></p> 32 </li> 33 </ul> 34 <h2>astro@4.9.1</h2> 35 <h3>Patch Changes</h3> 36 <ul> 37 <li><a href="https://redirect.github.com/withastro/astro/pull/11129">#11129</a> <a href="https://github.com/withastro/astro/commit/4bb926908d9a7ee134701c3e5a1b5e6ea688f843"><code>4bb9269</code></a> Thanks <a href="https://github.com/matthewp"><code>@matthewp</code></a>! - Prevent errors from adapters when i18n domains is not used</li> 38 </ul> 39 <h2>astro@4.9.0</h2> 40 <h3>Minor Changes</h3> 41 <ul> 42 <li> 43 <p><a href="https://redirect.github.com/withastro/astro/pull/11051">#11051</a> <a href="https://github.com/withastro/astro/commit/12a1bccc818af292cdd2a8ed0f3e3c042b9819b4"><code>12a1bcc</code></a> Thanks <a href="https://github.com/ematipico"><code>@ematipico</code></a>! - Introduces an experimental Container API to render <code>.astro</code> components in isolation.</p> 44 <p>This API introduces three new functions to allow you to create a new container and render an Astro component returning either a string or a Response:</p> 45 <ul> 46 <li><code>create()</code>: creates a new instance of the container.</li> 47 <li><code>renderToString()</code>: renders a component and return a string.</li> 48 <li><code>renderToResponse()</code>: renders a component and returns the <code>Response</code> emitted by the rendering phase.</li> 49 </ul> 50 <p>The first supported use of this new API is to enable unit testing. For example, with <code>vitest</code>, you can create a container to render your component with test data and check the result:</p> 51 <pre lang="js"><code>import { experimental_AstroContainer as AstroContainer } from 'astro/container'; 52 import { expect, test } from 'vitest'; 53 import Card from '../src/components/Card.astro'; 54 <p>test('Card with slots', async () => { 55 const container = await AstroContainer.create(); 56 const result = await container.renderToString(Card, { 57 slots: { 58 default: 'Card content', 59 }, 60 });</p> 61 <p>expect(result).toContain('This is a card'); 62 expect(result).toContain('Card content'); 63 </code></pre></p> 64 </li> 65 </ul> 66 <!-- raw HTML omitted --> 67 </blockquote> 68 <p>... (truncated)</p> 69 </details> 70 <details> 71 <summary>Changelog</summary> 72 <p><em>Sourced from <a href="https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md">astro's changelog</a>.</em></p> 73 <blockquote> 74 <h2>4.9.2</h2> 75 <h3>Patch Changes</h3> 76 <ul> 77 <li> 78 <p><a href="https://redirect.github.com/withastro/astro/pull/11138">#11138</a> <a href="https://github.com/withastro/astro/commit/98e0372cfd47a3e025be2ac68d1e9ebf06cf548b"><code>98e0372</code></a> Thanks <a href="https://github.com/ematipico"><code>@ematipico</code></a>! - You can now pass <code>props</code> when rendering a component using the Container APIs:</p> 79 <pre lang="js"><code>import { experimental_AstroContainer as AstroContainer } from 'astro/container'; 80 import Card from '../src/components/Card.astro'; 81 <p>const container = await AstroContainer.create(); 82 const result = await container.renderToString(Card, { 83 props: { 84 someState: true, 85 }, 86 }); 87 </code></pre></p> 88 </li> 89 </ul> 90 <h2>4.9.1</h2> 91 <h3>Patch Changes</h3> 92 <ul> 93 <li><a href="https://redirect.github.com/withastro/astro/pull/11129">#11129</a> <a href="https://github.com/withastro/astro/commit/4bb926908d9a7ee134701c3e5a1b5e6ea688f843"><code>4bb9269</code></a> Thanks <a href="https://github.com/matthewp"><code>@matthewp</code></a>! - Prevent errors from adapters when i18n domains is not used</li> 94 </ul> 95 <h2>4.9.0</h2> 96 <h3>Minor Changes</h3> 97 <ul> 98 <li> 99 <p><a href="https://redirect.github.com/withastro/astro/pull/11051">#11051</a> <a href="https://github.com/withastro/astro/commit/12a1bccc818af292cdd2a8ed0f3e3c042b9819b4"><code>12a1bcc</code></a> Thanks <a href="https://github.com/ematipico"><code>@ematipico</code></a>! - Introduces an experimental Container API to render <code>.astro</code> components in isolation.</p> 100 <p>This API introduces three new functions to allow you to create a new container and render an Astro component returning either a string or a Response:</p> 101 <ul> 102 <li><code>create()</code>: creates a new instance of the container.</li> 103 <li><code>renderToString()</code>: renders a component and return a string.</li> 104 <li><code>renderToResponse()</code>: renders a component and returns the <code>Response</code> emitted by the rendering phase.</li> 105 </ul> 106 <p>The first supported use of this new API is to enable unit testing. For example, with <code>vitest</code>, you can create a container to render your component with test data and check the result:</p> 107 <pre lang="js"><code>import { experimental_AstroContainer as AstroContainer } from 'astro/container'; 108 import { expect, test } from 'vitest'; 109 import Card from '../src/components/Card.astro'; 110 <p>test('Card with slots', async () => { 111 const container = await AstroContainer.create(); 112 const result = await container.renderToString(Card, { 113 slots: { 114 default: 'Card content', 115 }, 116 }); 117 </code></pre></p> 118 </li> 119 </ul> 120 <!-- raw HTML omitted --> 121 </blockquote> 122 <p>... (truncated)</p> 123 </details> 124 <details> 125 <summary>Commits</summary> 126 <ul> 127 <li><a href="https://github.com/withastro/astro/commit/cdf89a16c86172845fb5df5cb79b15f67fa7ca2f"><code>cdf89a1</code></a> [ci] release (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11140">#11140</a>)</li> 128 <li><a href="https://github.com/withastro/astro/commit/5af99dc8f1a144f3a2fdf254e25c42e83c7646dd"><code>5af99dc</code></a> [ci] format</li> 129 <li><a href="https://github.com/withastro/astro/commit/98e0372cfd47a3e025be2ac68d1e9ebf06cf548b"><code>98e0372</code></a> feat: pass props to container (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11138">#11138</a>)</li> 130 <li><a href="https://github.com/withastro/astro/commit/4c7949d1ae28f5597ec08cab788fe683197b0c3c"><code>4c7949d</code></a> [ci] release (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11132">#11132</a>)</li> 131 <li><a href="https://github.com/withastro/astro/commit/4bb926908d9a7ee134701c3e5a1b5e6ea688f843"><code>4bb9269</code></a> Prevent errors from adapters when i18n domains is not used (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11129">#11129</a>)</li> 132 <li><a href="https://github.com/withastro/astro/commit/50775925f9b2b50c3259dfd3d6f687d9af454884"><code>5077592</code></a> [ci] release (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11116">#11116</a>)</li> 133 <li><a href="https://github.com/withastro/astro/commit/9566fa08608be766df355be17d72a39ea7b99ed0"><code>9566fa0</code></a> Actions: Allow actions to be called on the server (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11088">#11088</a>)</li> 134 <li><a href="https://github.com/withastro/astro/commit/e71348e1381c42789daf2f9bb2366bf4ac9a4f15"><code>e71348e</code></a> [docs] fix config reference code formatting (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11119">#11119</a>)</li> 135 <li><a href="https://github.com/withastro/astro/commit/7bfe8aaaa1b32fdadb78b7e9c54c1f9aee9cd9ee"><code>7bfe8aa</code></a> [ci] format</li> 136 <li><a href="https://github.com/withastro/astro/commit/c7386ef2b3b42865ca6fbfe15cd17dd2cf5b0994"><code>c7386ef</code></a> [docs] update heading level in config reference (<a href="https://github.com/withastro/astro/tree/HEAD/packages/astro/issues/11118">#11118</a>)</li> 137 <li>Additional commits viewable in <a href="https://github.com/withastro/astro/commits/astro@4.9.2/packages/astro">compare view</a></li> 138 </ul> 139 </details> 140 <br /> 141 142 143 [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) 144 145 Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. 146 147 [//]: # (dependabot-automerge-start) 148 [//]: # (dependabot-automerge-end) 149 150 --- 151 152 <details> 153 <summary>Dependabot commands and options</summary> 154 <br /> 155 156 You can trigger Dependabot actions by commenting on this PR: 157 - `@dependabot rebase` will rebase this PR 158 - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it 159 - `@dependabot merge` will merge this PR after your CI passes on it 160 - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it 161 - `@dependabot cancel merge` will cancel a previously requested merge and block automerging 162 - `@dependabot reopen` will reopen this PR if it is closed 163 - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually 164 - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency 165 - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) 166 - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) 167 - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) 168 169 170 </details> 171 172 173 ## Comments 174 175 ### @dependabot[bot] — 2024-06-10T01:45:54Z 176 177 Superseded by #61. 178