vite-plugin-solid@3.0.0-next.20
Pre-releasePatch Changes
-
528a7bb: Move the
solid:client-build-firstbuildApp hook frompreto normal
order, and make its post-order/completecompanion defer to any other
plugin that declares a non-prebuildApphook of its own.Pre-order
buildApphooks are where host plugins do destructive
preparation: nitro v3'snitro:preparerm -rf's the output directory from
a pre-order hook. Sorted atpre, our client build could run before that
cleanup (hook order withinprefollows plugin registration), so the
client bundle and manifest it had just emitted were wiped, the subsequent
server build baked in the manifest-less fallback, and the production build
served 500s with no client assets — thesolid({ ssr })+nitro()
composition was broken out of the box.Normal order still satisfies the hook's original purpose (client before
any server-first orchestrator): config-levelbuilder.buildApp
orchestrators (@cloudflare/vite-plugin builds workers before the client)
are invoked by Vite only after all pre- and normal-order plugin hooks, and
hook-based orchestrators (nitro'snitro:main, cloudflare's companion
hook) declare post order. The/completehook now also treats another
plugin's non-prebuildApphook as a claim on the app build even before
it runs, instead of preempting a post-order orchestrator's staged build
(nitro prerenders and copies public assets before its final server bundle,
and knows which environments to skip). Plainbuilder: {}setups keep the
reinstated build-everything fallback, unchanged.Covered by a new turnkey e2e mode (builder-prepare) that builds against a
nitro-shaped host: a pre-order output-wiping hook plus a post-order
ssr-building orchestrator that skips already-built environments. -
60ba309: Resolve relative filter globs against the Vite root instead of
process.cwd().The server-functions plugin's default include glob
(src/**/*.{jsx,tsx,ts,js,mjs,cjs}) is relative, andcreateFilterresolved
it against the invocation directory — so runningvitefrom anywhere other
than the project root silently skipped server-function compilation entirely
(no transform, no registration). Both filters (the main plugin's
include/excludeandserverFunctions.filter) are now created in
configResolvedwith patterns resolved againstconfig.root; user-provided
relative patterns become root-relative too, and absolute patterns are
unaffected.