Skip to content

Add experimental TSRX support - #333

Merged
ryansolid merged 2 commits into
nextfrom
tsrx-support
Sep 2, 2026
Merged

Add experimental TSRX support#333
ryansolid merged 2 commits into
nextfrom
tsrx-support

Conversation

@ryansolid

Copy link
Copy Markdown
Member

Summary

  • route .tsrx modules through the native or Babel Solid compiler and strip retained TypeScript before Vite parses generated modules
  • expose compiler CSS sidecars as virtual CSS modules integrated with production extraction, client HMR, and SSR development style collection
  • include .tsrx in dependency scanning, lazy chunk handling, start entry discovery, and function-level \"use server\" processing

Depends on solidjs/solid#3086 and should remain draft until the compiler support ships in a Solid prerelease.

Test plan

  • pnpm build
  • Vite 8 production build with native compiler
  • Vite 8 production build with Babel compiler
  • Vite 8 browser test with native compiler
  • Vite 8 browser test with Babel compiler
  • native and Babel SSR entry builds
  • development transform, CSS sidecar, HMR update, source-map, and server-function smoke checks

Made with Cursor

@changeset-bot

changeset-bot Bot commented Aug 28, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 16d4844

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@solidjs/vite-plugin Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Aug 28, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/@solidjs/vite-plugin@333

commit: 16d4844

ryansolid and others added 2 commits September 2, 2026 12:50
Route .tsrx through both compilers, expose scoped CSS across dev, builds, and SSR, and compose function-level server directives after lowering.

Co-authored-by: Cursor <cursoragent@cursor.com>
rc.6 publishes the TSRX compiler frontends this branch routes
(solidjs/solid#3086). The workspace catalog moves to ^2.0.0-rc.6
(minimumReleaseAgeExclude extended per the existing pattern), and the
plugin's @solidjs/compiler and @solidjs/babel-plugin floors move from
^2.0.0-rc.3 to ^2.0.0-rc.6 — the real requirement, since older
compilers reject .tsrx outright. The published Babel frontend resolves
TSRX parsing through its optional peer @tsrx/core (exact 0.1.63), so
the vite-8 example installs it for the Babel half of the matrix; the
native binary bundles its own frontend.

Full gate green against published rc.6 (no linking): ssr 12/12 +
boundary 8/8, css-matrix 82/82 + bridge 19/19, start-ssr 366/366 +
http-bridge 10/10, start-client 45/45, start-env 47/47, cypress e2e
1/1, and the TSRX matrix on both compiler backends: vite-8 prod
builds, vitest browser 1/1, SSR entry builds, and dev
transform/CSS-sidecar/HMR/source-map/server-function smoke checks.

Co-authored-by: Cursor <cursoragent@cursor.com>
@socket-security

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​solidjs/​diagnostics@​2.0.0-rc.5 ⏵ 2.0.0-rc.6771009993 +1100
Updated@​solidjs/​babel-plugin@​2.0.0-rc.5 ⏵ 2.0.0-rc.680 +4100100 +193 +1100
Updated@​solidjs/​compiler@​2.0.0-rc.5 ⏵ 2.0.0-rc.681 +5100100 +192 +1100
Updated@​solidjs/​web@​2.0.0-rc.5 ⏵ 2.0.0-rc.6100 +110083 +197 +1100
Added@​tsrx/​core@​0.1.63941009799100
Updatedsolid-js@​2.0.0-rc.5 ⏵ 2.0.0-rc.6100 +110095 +196 +1100

View full report

@socket-security

Copy link
Copy Markdown

Warning

Review the following alerts detected in dependencies.

According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.

Action Severity Alert  (click "▶" to expand/collapse)
Warn Medium
Low adoption: npm @solidjs/compiler-darwin-arm64

Location: Package overview

From: pnpm-lock.yamlnpm/@solidjs/compiler@2.0.0-rc.6npm/@solidjs/compiler-darwin-arm64@2.0.0-rc.6

ℹ Read more on: This package | This alert | What are unpopular packages?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Unpopular packages may have less maintenance and contain other problems.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@solidjs/compiler-darwin-arm64@2.0.0-rc.6. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Warn Medium
Low adoption: npm @solidjs/compiler-win32-x64-msvc

Location: Package overview

From: pnpm-lock.yamlnpm/@solidjs/compiler@2.0.0-rc.6npm/@solidjs/compiler-win32-x64-msvc@2.0.0-rc.6

ℹ Read more on: This package | This alert | What are unpopular packages?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Unpopular packages may have less maintenance and contain other problems.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@solidjs/compiler-win32-x64-msvc@2.0.0-rc.6. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

View full report

@ryansolid
ryansolid marked this pull request as ready for review September 2, 2026 20:50
@ryansolid
ryansolid merged commit c458b5f into next Sep 2, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant