Skip to content
Merged
Show file tree
Hide file tree
Changes from 7 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
6 changes: 1 addition & 5 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,6 +1,2 @@
#!/usr/bin/env sh
FILES=$(git diff --cached --name-only)
[ -z "$FILES" ] && exit 0

# Run lint-staged on all staged
echo "$FILES" | npx lint-staged
pnpm exec nano-staged
4 changes: 0 additions & 4 deletions .lintstagedrc.js

This file was deleted.

4 changes: 4 additions & 0 deletions .nano-staged.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"*.{json,yml,md}": ["prettier --write"],
"*.{ts,js,cjs}": ["prettier --write", "eslint --fix", "vitest run related --passWithNoTests"]
}
16 changes: 8 additions & 8 deletions demos/vite-edge/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@
"dependencies": {
"@netlify/remix-edge-adapter": "workspace:*",
"@netlify/remix-runtime": "workspace:*",
"@remix-run/node": "^2.16.4",
"@remix-run/react": "^2.16.4",
"@remix-run/serve": "^2.16.4",
"@remix-run/node": "^2.17.5",
"@remix-run/react": "^2.17.5",
"@remix-run/serve": "^2.17.5",
"isbot": "^5.0.0",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"@netlify/functions": "^5.2.0",
"@remix-run/dev": "^2.16.4",
"@netlify/functions": "^5.3.0",
"@remix-run/dev": "^2.17.5",
"@types/react": "^18.2.20",
"@types/react-dom": "^18.2.7",
"@typescript-eslint/eslint-plugin": "^7.0.0",
Expand All @@ -33,9 +33,9 @@
"eslint-plugin-jsx-a11y": "^6.7.1",
"eslint-plugin-react": "^7.33.2",
"eslint-plugin-react-hooks": "^4.6.0",
"typescript": "^5.1.6",
"vite": "^8.0.0",
"vite-tsconfig-paths": "^5.1.4"
"typescript": "^6.0.3",
"vite": "^8.0.16",
"vite-tsconfig-paths": "^6.1.1"
Comment thread
serhalp marked this conversation as resolved.
},
"engines": {
"node": ">=20.6.1"
Expand Down
14 changes: 7 additions & 7 deletions demos/vite-functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
},
"dependencies": {
"@netlify/remix-adapter": "workspace:*",
"@remix-run/node": "^2.16.4",
"@remix-run/react": "^2.16.4",
"@remix-run/serve": "^2.16.4",
"@remix-run/node": "^2.17.5",
"@remix-run/react": "^2.17.5",
"@remix-run/serve": "^2.17.5",
"isbot": "^5.0.0",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"@remix-run/dev": "^2.16.4",
"@remix-run/dev": "^2.17.5",
"@types/react": "^18.2.20",
"@types/react-dom": "^18.2.7",
"@typescript-eslint/eslint-plugin": "^7.0.0",
Expand All @@ -31,9 +31,9 @@
"eslint-plugin-jsx-a11y": "^6.7.1",
"eslint-plugin-react": "^7.33.2",
"eslint-plugin-react-hooks": "^4.6.0",
"typescript": "^5.1.6",
"vite": "^8.0.0",
"vite-tsconfig-paths": "^5.1.4"
"typescript": "^6.0.3",
"vite": "^8.0.16",
"vite-tsconfig-paths": "^6.1.1"
},
"engines": {
"node": ">=20.6.1"
Expand Down
35 changes: 18 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@
"test": "pnpm run typecheck && pnpm run format:check && pnpm run test:unit && pnpm run test:e2e",
"test:e2e": "pnpm run build:packages && pnpm exec playwright test",
"test:unit": "vitest",
"typecheck": "tsc --noEmit"
"typecheck": "run-s typecheck:node typecheck:deno",
"typecheck:node": "tsc --noEmit -p tsconfig.json",
"typecheck:deno": "tsc --noEmit -p tsconfig.deno.json"
},
"repository": {
"type": "git",
Expand All @@ -33,27 +35,26 @@
},
"homepage": "https://github.com/netlify/remix-compute#readme",
"devDependencies": {
"@commitlint/cli": "^20.0.0",
"@commitlint/cli": "^21.0.2",
"@netlify/eslint-config-node": "^7.0.1",
"@playwright/test": "^1.44.0",
"@remix-run/eslint-config": "^2.9.2",
"@types/node": "^20.0.0",
"@typescript-eslint/eslint-plugin": "^7.0.0",
"@typescript-eslint/parser": "^7.0.0",
"@playwright/test": "^1.61.0",
"@remix-run/eslint-config": "^2.17.5",
"@types/node": "^22.19.21",
"@typescript-eslint/eslint-plugin": "^8.61.1",
"@typescript-eslint/parser": "^8.61.1",
"eslint": "^8.33.0",
"eslint-plugin-playwright": "^2.0.0",
"eslint-prettier-config": "^1.0.1",
"execa": "^8.0.1",
"fast-glob": "^3.3.2",
"husky": "^9.0.11",
"lint-staged": "^16.0.0",
"netlify-cli": "^24.11.3",
"husky": "^9.1.7",
"nano-staged": "^1.0.2",
Comment thread
serhalp marked this conversation as resolved.
"netlify-cli": "^26.1.0",
"npm-run-all2": "^8.0.0",
"p-limit": "^7.0.0",
"prettier": "^3.0.0",
"publint": "^0.3.15",
"typescript": "^5.0.0",
"vitest": "^4.0.0"
"p-limit": "^7.3.0",
"prettier": "^3.8.4",
"publint": "^0.3.21",
"tinyglobby": "^0.2.17",
"typescript": "7.0.1-rc",
"vitest": "^4.1.9"
},
"dependencies": {
"@netlify/edge-functions": "^3.0.6",
Expand Down
10 changes: 5 additions & 5 deletions packages/remix-adapter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@
"isbot": "^5.0.0"
},
"devDependencies": {
"@netlify/functions": "^5.2.0",
"@remix-run/dev": "^2.16.4",
"@remix-run/react": "^2.16.4",
"@netlify/functions": "^5.3.0",
"@remix-run/dev": "^2.17.5",
"@remix-run/react": "^2.17.5",
"@types/react": "^18.0.27",
"@types/react-dom": "^18.0.10",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"tsup": "^8.0.2",
"vite": "^8.0.0"
"tsup": "^8.5.1",
"vite": "^8.0.16"
Comment thread
serhalp marked this conversation as resolved.
},
"peerDependencies": {
"vite": ">=5.0.0"
Expand Down
6 changes: 3 additions & 3 deletions packages/remix-edge-adapter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,13 @@
"isbot": "^5.0.0"
},
"devDependencies": {
"@remix-run/react": "^2.16.4",
"@remix-run/react": "^2.17.5",
"@types/react": "^18.0.27",
"@types/react-dom": "^18.0.10",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"tsup": "^8.0.2",
"vite": "^8.0.0"
"tsup": "^8.5.1",
"vite": "^8.0.16"
},
"peerDependencies": {
"vite": ">=5.0.0"
Expand Down
4 changes: 2 additions & 2 deletions packages/remix-runtime/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
},
"homepage": "https://github.com/netlify/remix-compute#readme",
"devDependencies": {
"@remix-run/server-runtime": "^2.12.0",
"tsup": "^8.0.2"
"@remix-run/server-runtime": "^2.17.5",
"tsup": "^8.5.1"
},
"peerDependencies": {
"@remix-run/server-runtime": "^2.9.2"
Expand Down
2 changes: 1 addition & 1 deletion packages/remix-runtime/src/crypto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ async function createKey(secret: string, usages: CryptoKey['usages']): Promise<C
return key
}

function byteStringToUint8Array(byteString: string): Uint8Array {
function byteStringToUint8Array(byteString: string): Uint8Array<ArrayBuffer> {
const array = new Uint8Array(byteString.length)

for (let i = 0; i < byteString.length; i++) {
Expand Down
9 changes: 4 additions & 5 deletions packages/remix-runtime/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@
"extends": "../../tsconfig.json",
"compilerOptions": {
"rootDir": ".",
"outDir": "./build"
"outDir": "./build",
"types": []
},
"include": ["./src"]
// "references": [
// { "path": "../remix-runtime/tsconfig.json"}
// ]
"include": ["./src"],
"exclude": ["node_modules"]
}
6 changes: 3 additions & 3 deletions packages/vite-plugin-react-router/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
],
"scripts": {
"prepack": "pnpm run build",
"build": "rm -rf dist && tsup-node",
"build": "tsdown",
"build:watch": "pnpm run build --watch",
"publint": "publint --strict"
},
Expand Down Expand Up @@ -63,8 +63,8 @@
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-router": "^7.9.4",
"tsup": "^8.0.2",
"vite": "^8.0.0"
"tsdown": "^0.22.3",
"vite": "^8.0.16"
},
"peerDependencies": {
"react-router": ">=7.9.0",
Expand Down
3 changes: 2 additions & 1 deletion packages/vite-plugin-react-router/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@
"jsx": "react-jsx",
"outDir": "./build"
},
"include": ["./src"]
"include": ["./src"],
"exclude": ["node_modules"]
}
21 changes: 21 additions & 0 deletions packages/vite-plugin-react-router/tsdown.config.mts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { defineConfig } from 'tsdown'

// `react`/`react-dom` are devDependencies, so tsdown won't auto-externalize them (it only does so
// for `dependencies`/`peerDependencies`). Keep them external so the runtime resolves the correct build.
const external = [/^react(-dom)?(\/.*)?$/]

export default defineConfig({
entry: {
index: 'src/index.ts',
serverless: 'src/runtimes/netlify-functions.ts',
edge: 'src/runtimes/netlify-edge-functions.ts',
'entry.server.edge': 'src/entry.server.edge.tsx',
},
format: ['esm'],
dts: true,
target: 'node22',
external,

@pieh pieh Jun 22, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://tsdown.dev/guide/migrate-from-tsup#deprecated-but-compatible-options

seems like tsdown blessed way is to use deps.neverBundle (with external being supported, but deprecated)

noted in https://github.com/netlify/remix-compute/actions/runs/27965209479/job/82757080857?pr=711#step:7:19

packages/vite-plugin-react-router build:  WARN  `external` is deprecated. Use `deps.neverBundle` instead.

// Derive extensions from the package's `type` (`.mjs`/`.d.mts` for ESM, `.js`/`.d.ts` for
// CJS) instead of tsdown's fixed `.mjs`/`.cjs`, to match the paths in `exports`.
fixedExtension: false,
})
16 changes: 0 additions & 16 deletions packages/vite-plugin-react-router/tsup.config.ts

This file was deleted.

Loading
Loading