summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
Diffstat (limited to 'packages')
-rw-r--r--packages/astro/CHANGELOG.md100
-rw-r--r--packages/astro/package.json2
-rw-r--r--packages/integrations/cloudflare/CHANGELOG.md8
-rw-r--r--packages/integrations/cloudflare/package.json2
-rw-r--r--packages/integrations/mdx/CHANGELOG.md6
-rw-r--r--packages/integrations/mdx/package.json2
-rw-r--r--packages/integrations/preact/CHANGELOG.md6
-rw-r--r--packages/integrations/preact/package.json2
8 files changed, 41 insertions, 87 deletions
diff --git a/packages/astro/CHANGELOG.md b/packages/astro/CHANGELOG.md
index 3603548b9..77d2b930c 100644
--- a/packages/astro/CHANGELOG.md
+++ b/packages/astro/CHANGELOG.md
@@ -1,5 +1,19 @@
# astro
+## 1.0.2
+
+### Patch Changes
+
+- [#4247](https://github.com/withastro/astro/pull/4247) [`714a8399e`](https://github.com/withastro/astro/commit/714a8399e20f334d2ba341c98d8ef5d590af9c39) Thanks [@matthewp](https://github.com/matthewp)! - Return 404 status code for 404.astro in SSR
+
+* [#4240](https://github.com/withastro/astro/pull/4240) [`561a34d91`](https://github.com/withastro/astro/commit/561a34d91209c9d4959f74beaa17008edb27ff5d) Thanks [@matthewp](https://github.com/matthewp)! - Properly invalidate Astro modules when a child script updates in HMR
+
+- [#4234](https://github.com/withastro/astro/pull/4234) [`c38e7f189`](https://github.com/withastro/astro/commit/c38e7f1890ba5bc97ddacee91ea196bcfc7652e6) Thanks [@bluwy](https://github.com/bluwy)! - Remove dev server during build
+
+* [#4213](https://github.com/withastro/astro/pull/4213) [`f8e385339`](https://github.com/withastro/astro/commit/f8e3853394c2f2f48fac4b5eb2284e1960e59a13) Thanks [@bluwy](https://github.com/bluwy)! - Bump Vite to 3.0.5
+
+- [#4225](https://github.com/withastro/astro/pull/4225) [`e918b3883`](https://github.com/withastro/astro/commit/e918b3883e156a0de2148517b619a2cf451917d2) Thanks [@mayank99](https://github.com/mayank99)! - `astro add` now supports `-y`
+
## 1.0.1
### Patch Changes
@@ -456,18 +470,7 @@ The **Astro v1.0.0 Release Candidate** comes includes new features, tons of bug
Astro supports streaming in its templates. Any time Astro encounters an async boundary it will stream out HTML that occurs before it. For example:
```astro
- ---
- import LoadTodos from '../components/LoadTodos.astro';
- ---
- <html>
- <head>
- <title>App</title>
- </head>
- <body>
- <LoadTodos />
- </body>
- </html>
```
In this arbtrary example Astro will streaming out the `<head>` section and everything else until it encounters `<LoadTodos />` and then stop. LoadTodos, which is also an Astro component will stream its contents as well; stopping and waiting at any other asynchronous components.
@@ -475,15 +478,7 @@ The **Astro v1.0.0 Release Candidate** comes includes new features, tons of bug
As part of this Astro also now supports async iterables within its templates. This means you can do this:
```astro
- <ul>
- {(async function* () {
- for (const number of numbers) {
- await wait(1000);
- yield <li>Number: {number}</li>;
- yield '\n';
- }
- })()}
- </ul>
+
```
Which will stream out `<li>`s one at a time, waiting a second between each.
@@ -2618,9 +2613,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
This change adds support for hoisted scripts, allowing you to bundle scripts together for a page and hoist them to the top (in the head):
```astro
- <script hoist>
- // Anything goes here!
- </script>
+
```
- Updated dependencies [5d2ea578]
@@ -2722,21 +2715,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
An example usage:
```astro
- ---
- import BarChart from '../components/BarChart.jsx';
- ---
-
- <BarChart client:only />
- <!--
- If multiple renderers are included in the Astro config, this will ensure that the component is hydrated with * the Preact renderer.
- -->
- <BarChart client:only="preact" />
-
- <!--
- If a custom renderer is required, use the same name provided in the Astro config.
- -->
- <BarChart client:only="my-custom-renderer" />
```
This allows you to import a chart component dependent on d3.js while making sure that the component isn't rendered at all at build time.
@@ -2760,16 +2739,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
An example usage:
```astro
- ---
- import BarChart from '../components/BarChart.jsx';
- ---
- <BarChart client:only />
- /** * If multiple renderers are included in the Astro config, * this will ensure that the
- component is hydrated with * the Preact renderer. */
- <BarChart client:only="preact" />
- /** * If a custom renderer is required, use the same name * provided in the Astro config. */
- <BarChart client:only="my-custom-renderer" />
```
This allows you to import a chart component dependent on d3.js while making sure that the component isn't rendered at all at build time.
@@ -2917,11 +2887,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
The new `client:media` hydrator allows you to define a component that should only be loaded when a media query matches. An example usage:
```astro
- ---
- import Sidebar from '../components/Sidebar.jsx';
- ---
- <Sidebar client:media="(max-width: 700px)" />
```
This allows you to define components which, for example, only run on mobile devices. A common example is a slide-in sidebar that is needed to add navigation to a mobile app, but is never displayed in desktop view.
@@ -2939,12 +2905,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
**index.astro**
```astro
- ---
- import Sidebar from '../components/Sidebar.jsx';
- import { MOBILE } from '../media.js';
- ---
- <Sidebar client:media={MOBILE} />;
```
### Patch Changes
@@ -3069,11 +3030,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
The new `client:media` hydrator allows you to define a component that should only be loaded when a media query matches. An example usage:
```astro
- ---
- import Sidebar from '../components/Sidebar.jsx';
- ---
- <Sidebar client:media="(max-width: 700px)" />
```
This allows you to define components which, for example, only run on mobile devices. A common example is a slide-in sidebar that is needed to add navigation to a mobile app, but is never displayed in desktop view.
@@ -3091,12 +3048,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
**index.astro**
```astro
- ---
- import Sidebar from '../components/Sidebar.jsx';
- import { MOBILE } from '../media.js';
- ---
- <Sidebar client:media={MOBILE} />
```
### Patch Changes
@@ -3265,12 +3217,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
Astro frontmatter scripts are TypeScript! Because of this, we can leverage TypeScript types to define the shape of your props.
```astro
- ---
- export interface Props {
- text?: string;
- }
- const { text = 'Hello world!' } = Astro.props as Props;
- ---
+
```
> **Note** Casting `Astro.props as Props` is a temporary workaround. We expect our Language Server to handle this automatically soon!
@@ -3280,13 +3227,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
One of the great things about this change is that it's straight-forward to access _any_ props. Just use `...props`!
```astro
- ---
- export interface Props {
- text?: string;
- [attr: string]: unknown;
- }
- const { text = 'Hello world!', ...props } = Astro.props as Props;
- ---
+
```
### What about prop validation?
@@ -3294,12 +3235,7 @@ For convenience, you may now also move your `astro.config.js` file to a top-leve
We considered building prop validation into Astro, but decided to leave that implementation up to you! This way, you can use any set of tools you like.
```astro
- ---
- const { text = 'Hello world!' } = Astro.props;
- if (typeof text !== 'string')
- throw new Error(`Expected "text" to be of type "string" but recieved "${typeof string}"!`);
- ---
```
### Patch Changes
diff --git a/packages/astro/package.json b/packages/astro/package.json
index f6cf58e68..7fc26ec16 100644
--- a/packages/astro/package.json
+++ b/packages/astro/package.json
@@ -1,6 +1,6 @@
{
"name": "astro",
- "version": "1.0.1",
+ "version": "1.0.2",
"description": "Astro is a modern site builder with web best practices, performance, and DX front-of-mind.",
"type": "module",
"author": "withastro",
diff --git a/packages/integrations/cloudflare/CHANGELOG.md b/packages/integrations/cloudflare/CHANGELOG.md
index 9280f7081..4014369f0 100644
--- a/packages/integrations/cloudflare/CHANGELOG.md
+++ b/packages/integrations/cloudflare/CHANGELOG.md
@@ -1,5 +1,11 @@
# @astrojs/cloudflare
+## 1.0.1
+
+### Patch Changes
+
+- [#4232](https://github.com/withastro/astro/pull/4232) [`bfbd32588`](https://github.com/withastro/astro/commit/bfbd32588f7e2c0a9e43cd1a571a0dc9c5f7e645) Thanks [@Ekwuno](https://github.com/Ekwuno)! - Update README
+
## 1.0.0
### Major Changes
@@ -58,7 +64,7 @@
The new `Astro.clientAddress` property allows you to get the IP address of the requested user.
```astro
- <div>Your address {Astro.clientAddress}</div>
+
```
This property is only available when building for SSR, and only if the adapter you are using supports providing the IP address. If you attempt to access the property in a SSG app it will throw an error.
diff --git a/packages/integrations/cloudflare/package.json b/packages/integrations/cloudflare/package.json
index 1c13bdbef..c5341d7d0 100644
--- a/packages/integrations/cloudflare/package.json
+++ b/packages/integrations/cloudflare/package.json
@@ -1,7 +1,7 @@
{
"name": "@astrojs/cloudflare",
"description": "Deploy your site to cloudflare pages functions",
- "version": "1.0.0",
+ "version": "1.0.1",
"type": "module",
"types": "./dist/index.d.ts",
"author": "withastro",
diff --git a/packages/integrations/mdx/CHANGELOG.md b/packages/integrations/mdx/CHANGELOG.md
index c8e389628..08a6037e8 100644
--- a/packages/integrations/mdx/CHANGELOG.md
+++ b/packages/integrations/mdx/CHANGELOG.md
@@ -1,5 +1,11 @@
# @astrojs/mdx
+## 0.8.2
+
+### Patch Changes
+
+- [#4237](https://github.com/withastro/astro/pull/4237) [`9d5ab5508`](https://github.com/withastro/astro/commit/9d5ab55086964fbede17da3d78c209c6d8d13711) Thanks [@bholmesdev](https://github.com/bholmesdev)! - Update "Astro.props.content" -> "Astro.props.frontmatter" in README
+
## 0.8.1
### Patch Changes
diff --git a/packages/integrations/mdx/package.json b/packages/integrations/mdx/package.json
index 3aca2ea27..d8f62ac23 100644
--- a/packages/integrations/mdx/package.json
+++ b/packages/integrations/mdx/package.json
@@ -1,7 +1,7 @@
{
"name": "@astrojs/mdx",
"description": "Use MDX within Astro",
- "version": "0.8.1",
+ "version": "0.8.2",
"type": "module",
"types": "./dist/index.d.ts",
"author": "withastro",
diff --git a/packages/integrations/preact/CHANGELOG.md b/packages/integrations/preact/CHANGELOG.md
index b2c7cfe41..8fd92823a 100644
--- a/packages/integrations/preact/CHANGELOG.md
+++ b/packages/integrations/preact/CHANGELOG.md
@@ -1,5 +1,11 @@
# @astrojs/preact
+## 1.0.1
+
+### Patch Changes
+
+- [#4213](https://github.com/withastro/astro/pull/4213) [`f8e385339`](https://github.com/withastro/astro/commit/f8e3853394c2f2f48fac4b5eb2284e1960e59a13) Thanks [@bluwy](https://github.com/bluwy)! - Fix compat support for libraries
+
## 1.0.0
### Major Changes
diff --git a/packages/integrations/preact/package.json b/packages/integrations/preact/package.json
index 114d09c21..137b789a6 100644
--- a/packages/integrations/preact/package.json
+++ b/packages/integrations/preact/package.json
@@ -1,7 +1,7 @@
{
"name": "@astrojs/preact",
"description": "Use Preact components within Astro",
- "version": "1.0.0",
+ "version": "1.0.1",
"type": "module",
"types": "./dist/index.d.ts",
"author": "withastro",