Add @nanostores/preact to ALWAYS_NOEXTERNAL (#3667)

* chore: add nanostores/preact to ALWAYS_NOEXTERNAL

* chore: update comment to reference pR

* chore: changeset
This commit is contained in:
Ben Holmes 2022-06-22 11:38:59 -04:00 committed by GitHub
parent fc74dc4a8c
commit df02fad13e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 1 deletions

View file

@ -0,0 +1,5 @@
---
'astro': patch
---
Fix: add @nanostores/preact to ALWAYS_NOEXTERNAL list for easier onboarding

View file

@ -28,7 +28,11 @@ const ALWAYS_EXTERNAL = new Set([
'whatwg-url',
]);
const ALWAYS_NOEXTERNAL = new Set([
'astro', // This is only because Vite's native ESM doesn't resolve "exports" correctly.
// This is only because Vite's native ESM doesn't resolve "exports" correctly.
'astro',
// Handle recommended nanostores. Only @nanostores/preact is required from our testing!
// Full explanation and related bug report: https://github.com/withastro/astro/pull/3667
'@nanostores/preact',
]);
// note: ssr is still an experimental API hence the type omission from `vite`