You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR #11439 removed @remix-run/node-serve and the remix/node-serve export from the current beta so remix@next no longer pulls in the uWebSockets.js GitHub dependency that blocked pnpm and Deno installs. This is intended to be temporary.
We should restore node-serve in a future beta once its native dependency path is npm-only and package-manager friendly.
Proposal
Restore the package using a Remix-owned facade for uWebSockets.js plus thin native packages split by OS/architecture. The dependency graph should look like this:
@remix-run/node-serve should import the facade instead of upstream directly:
import*asuWSfrom'@remix-run/uwebsockets-js'
@remix-run/uwebsockets-js should be a small wrapper/facade package with no native binaries in its own tarball. It should expose the upstream API shape, ship ESM and CJS entry points, include the upstream types, and select the installed platform package at runtime.
Each platform package should be a thin npm-published copy of the upstream payload for exactly one OS/arch combination. It should contain the relevant native binaries, the JS wrapper files needed to load them, upstream type definitions, upstream license text, and source attribution.
Add @remix-run/uwebsockets-js as the facade package and update node-serve to import it instead of uWebSockets.js directly.
Add platform-specific packages for the native payload, one package per supported OS/arch combination.
Add a reproducible sync script that vendors from a pinned upstream uWebSockets.js commit or tag and records source attribution for each package.
Preserve upstream Apache-2.0 license text and source attribution in the facade/platform packages.
Ensure the platform packages do not become regular hard dependencies of remix. If they live under packages/, update scripts/generate-remix.ts with an explicit internal/optional-native package skip mechanism so they are not auto-added to the umbrella package dependencies or exports.
Make the facade throw a clear runtime error when optional dependencies were disabled, the current platform is unsupported, or the current Node ABI has no matching native binary.
Restore the remix/node-serve export and add release notes once normal installs work through npm-only dependencies.
Acceptance Criteria
npm i remix@next, pnpm add remix@next, and deno add npm:remix@next do not require GitHub or other non-npm transitive dependencies.
Users normally do not need to manually install platform-specific packages.
The installed native payload is scoped to the user’s current OS/arch instead of shipping every platform in the default dependency tarball.
remix/node-serve works for supported platforms and fails with actionable messaging for unsupported or optional-dependency-disabled installs.
Background
PR #11439 removed
@remix-run/node-serveand theremix/node-serveexport from the current beta soremix@nextno longer pulls in theuWebSockets.jsGitHub dependency that blocked pnpm and Deno installs. This is intended to be temporary.We should restore
node-servein a future beta once its native dependency path is npm-only and package-manager friendly.Proposal
Restore the package using a Remix-owned facade for
uWebSockets.jsplus thin native packages split by OS/architecture. The dependency graph should look like this:@remix-run/node-serveshould import the facade instead of upstream directly:@remix-run/uwebsockets-jsshould be a small wrapper/facade package with no native binaries in its own tarball. It should expose the upstream API shape, ship ESM and CJS entry points, include the upstream types, and select the installed platform package at runtime.Example optional dependency shape:
{ "name": "@remix-run/uwebsockets-js", "optionalDependencies": { "@remix-run/uwebsockets-js-darwin-arm64": "20.66.0", "@remix-run/uwebsockets-js-darwin-x64": "20.66.0", "@remix-run/uwebsockets-js-linux-arm64-gnu": "20.66.0", "@remix-run/uwebsockets-js-linux-x64-gnu": "20.66.0", "@remix-run/uwebsockets-js-win32-x64": "20.66.0" } }Each platform package should be a thin npm-published copy of the upstream payload for exactly one OS/arch combination. It should contain the relevant native binaries, the JS wrapper files needed to load them, upstream type definitions, upstream license text, and source attribution.
Example platform package metadata:
{ "name": "@remix-run/uwebsockets-js-linux-x64-gnu", "version": "20.66.0", "license": "Apache-2.0", "main": "./uws.js", "types": "./index.d.ts", "os": ["linux"], "cpu": ["x64"], "libc": ["glibc"] }Implementation Plan
packages/node-servefrom the removal in PR Remove node-serve from next beta #11439.@remix-run/uwebsockets-jsas the facade package and updatenode-serveto import it instead ofuWebSockets.jsdirectly.uWebSockets.jscommit or tag and records source attribution for each package.remix. If they live underpackages/, updatescripts/generate-remix.tswith an explicit internal/optional-native package skip mechanism so they are not auto-added to the umbrella package dependencies or exports.remix/node-serveexport and add release notes once normal installs work through npm-only dependencies.Acceptance Criteria
npm i remix@next,pnpm add remix@next, anddeno add npm:remix@nextdo not require GitHub or other non-npm transitive dependencies.remix/node-serveworks for supported platforms and fails with actionable messaging for unsupported or optional-dependency-disabled installs.