Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .changeset/pre.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@
"compiler-next-37",
"compiler-package-rename",
"compiler-range-next-43",
"css-module-classes",
"dedupe-solid-in-builds",
"deployment-contract",
"dev-asset-resolver-convergence",
"dev-boundaries-ssr",
"dev-css-and-client-manifest",
Expand All @@ -54,11 +56,13 @@
"diagnostics-detection-declaration",
"diagnostics-endpoint",
"diagnostics-startup-banner",
"docs-setup-order-leak-scan",
"document-hmr-full-reload",
"drop-legacy-server-function-addressing",
"drop-sc-bootstrap-head-splice",
"drop-vite-lt-6",
"empty-dragons-grow",
"esm-only",
"event-first-middleware-nonce",
"external-dev-styles",
"fetchable-start-handler",
Expand All @@ -70,12 +74,15 @@
"handle-request-nonce-pair",
"handler-edge-commit-fold",
"honor-host-noexternal-patterns",
"hook-filters",
"host-integration-extension-points",
"http-bridge-h2-tls-abort",
"id-hash-second-segment",
"inject-deployment-secret",
"jest-dom-resolve-from-project-root",
"jest-dom-v7-next",
"jsx-asset-urls",
"lazy-babel",
"lazy-entry-eliminated-importers",
"lazy-entry-rolldown-reclassify",
"lazy-load-native-compiler",
Expand All @@ -90,6 +97,7 @@
"native-compiler-option",
"native-event-seam",
"native-server-function-transform",
"no-cypress-types",
"no-jsdom-default",
"no-tla-server-env",
"node-22-floor-signals-dedupe",
Expand All @@ -102,6 +110,8 @@
"plugin-package-rename",
"production-error-boundary",
"protect-configured-entry-chunks",
"public-api-renames",
"public-api-types",
"query-before-extension",
"rc10-live-address-preview-passthrough-prebundle",
"refresh-boolean",
Expand All @@ -128,17 +138,21 @@
"server-environments-reload",
"server-function-build-id",
"server-function-manifest-ids",
"server-functions-build-id-511",
"server-functions-client-outdir",
"server-functions-client-runtime-prebundle",
"server-functions-client-subpath-prebundle",
"server-functions-compiler",
"server-functions-default-runtime",
"server-functions-host-environments",
"server-functions-public-signature",
"server-functions-server-setup",
"server-functions-server-subpath-docs",
"server-functions-turnkey",
"signals-optimize-include",
"six-lions-joke",
"solid-compiler-packages",
"solid-env-virtual-ids",
"solid-rc13",
"solid-rc14",
"solid-rc16",
Expand All @@ -158,7 +172,9 @@
"start-lifecycle-names",
"start-mode-terminology",
"start-node-entry",
"start-node-server",
"start-render-mode",
"start-request-event-type",
"start-setup-hook",
"strip-entry-module-url",
"support-tsrx-vite",
Expand Down
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Changelog

## 3.0.0-next.54

### Patch Changes

- 9dabc25: In builds, inline CSS module class names used directly in JSX attributes (`class={styles.button}`, template literals of them, named imports), so they compile into the element's template instead of a reactive effect. The stylesheet is kept even when every use was inlined.
- cb5c5ee: Document the deployment contract provider plugins can rely on from 3.0: the `client` and `ssr` environments, the `ssr` environment's `index` handler entry with its `{ fetch }` and `handleRequest` exports, client-first build order, output locations, client-mode output, and the dev handover. A test builds an app through a stand-in provider that relies on it.
- e4538d8: Correct the README on why `start.serverSetup` cannot be a static import (the whole graph loads before any module runs, and an async module does not hold back the imports after it) and on what the env leak scan skips.
- 314a961: Ship the plugin as ESM only, which makes the package about 1 MB smaller unpacked. Vite is ESM-only already, and on the supported Node versions (22.12 and later) `require('@solidjs/vite-plugin')` loads the ESM build with the same exports (Node 22.12 prints a one-time experimental warning; 22.13 and later don't).
- b06c37e: Use Vite hook filters on the plugin's `transform`, `resolveId` and `load` hooks, so under Rolldown the JavaScript side only runs for modules a hook can act on. In a 2,100-module start-mode build, this cut build time by about 8% with identical output.
- 0d50833: Resolve static asset URLs in JSX: a relative `src`, `srcset`, `poster` or `href` on `<img>`, `<source>`, `<video>`, `<image>` and `<use>` becomes an import of the asset, and a `/` URL naming a public-directory file follows `base`, relative bases (Electron builds) included. The compiler used to put them in the template as written, so relative URLs resolved against the page and public URLs ignored `base`.
- 0d45ea0: Load Babel and `@solidjs/babel-plugin` on first use instead of at import. The default native compiler never calls them, so importing the plugin takes about half as long (roughly 100 ms down to 50 ms).
- 9a96d74: The published package no longer includes type declarations for the plugin's own Cypress tests (`dist/types/cypress`).
- 51f9a7d: Rename the types entry `@solidjs/vite-plugin/virtual-solid-manifest` to `@solidjs/vite-plugin/virtual-modules` (it declares every virtual module the plugin serves) and `css.filter` to `css.devInline` (it picks which module graphs dev SSR crawls for the CSS it inlines). Remove `serverFunctions.manifest`: the module id is always `virtual:solid-server-function-manifest`. The old option names fail at config time with a message naming the replacement.
- e35b1e3: Add the `StartServerRenderSetup` and `StartServerRenderContext` types (a `start.serverRenderSetup` module's default export, and the context an authored server entry's `render` receives), and type the options of `handleServerFunctionRequest` and `handleRequest`'s `serverFunctions` with the runtime's `HandleServerFunctionOptions`, so a misspelled option no longer type-checks. The README now documents the client build's `.vite/solid-server-functions.json` (`PersistedServerFunctionManifest`), and option docs that still mentioned solid-refresh or `@solidjs/babel-plugin` are corrected.
- cfddf51: Server-function skew protection now holds when a host builds the app in one process and relocates the client output (nitro): once the same plugin instance built the client, the server build uses that build's id and discoveries from memory instead of reading `.vite/solid-server-functions.json`, which could be stale. Calls are also stamped when the app configures the client through `@solidjs/web/server-functions/client`; its `prepareRequest` used to drop the stamp.
- d6be37a: The server build now reads the client build's `.vite/solid-server-functions.json` from where the client build wrote it in the same process, then from the client environment's configured `outDir`, and only then from `dist/client`. With a custom client `outDir` (a single `vite build`, or `environments.client.build.outDir` set), client-only server functions now register and the build id check runs. Setting `serverFunctions.runtime` to the default runtime no longer turns the build id check off.
- b92affb: Rename `serverFunctions.configure` to `serverFunctions.serverSetup`: it is a server-only module that runs once before any server-function call is handled, the same role `start.serverSetup` plays for the whole server. The old key fails at config time with a message naming the replacement.
- 4a8eb04: Rename the env modules `virtual:env/server` and `virtual:env/client` to `virtual:solid-env/server` and `virtual:solid-env/client`, matching the plugin's other `virtual:solid-*` modules. Importing an old ID fails with a message naming the new one, and the generated `solid-env.d.ts` declares the new IDs.
- 262d48d: Rename `start.node` to `start.nodeServer`: it emits a ready-to-run Node server (`dist/server/node.js`) and does not change the build target, which `node: true` could suggest. The old key fails at config time with a message naming the replacement.
- 5cfe7f8: Add the `StartRequestEvent` type: the request event in start mode, with the `response` head every start-mode event carries and the optional `nativeEvent`. `StartMiddleware` now receives it, so `event.response.headers.set(...)` type-checks in middleware; `@solidjs/web`'s base `RequestEvent` declares neither field.

## 3.0.0-next.53

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@solidjs/vite-plugin",
"version": "3.0.0-next.53",
"version": "3.0.0-next.54",
"description": "solid-js integration plugin for Vite",
"type": "module",
"engines": {
Expand Down
Loading