add more detail on "no jsx components" migration guide section

This commit is contained in:
Fred K. Schott 2021-11-19 15:02:24 -08:00 committed by GitHub
parent 8d7abfcbc5
commit b35e049184
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -82,9 +82,12 @@ setup: |
</MyReactComponent>
```
## JSX in Frontmatter
## Components in Frontmatter
Previously, you could create mini Astro Components inside of the Astro Frontmatter, using JSX syntax instead of Astro's component syntax. This was always a bit of a hack, but in the new compiler it became impossible to support. We hope to re-introduce this feature in a future release of Astro using a different, non-JSX API.
To migrate to v0.21, please convert all JSX Astro components (that is, any Astro components created inside of another component's frontmatter) to standalone components.
In Astro v0.21, JSX cannot be used within Frontmatter.
## Environment Variables