Skip to content

Commit a1b4cc0

Browse files
authored
Merge branch 'main' into 07-05-feat_rsc_support_directive_pattern_transform
2 parents 609a193 + 0fc7fcd commit a1b4cc0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+804
-325
lines changed

.github/workflows/ci-rsc.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
- name: install rolldown
5959
if: ${{ matrix.rolldown }}
6060
run: |
61-
echo 'overrides: { vite: "npm:rolldown-vite@latest" }' >> pnpm-workspace.yaml
61+
sed -i '/^overrides:/a\ vite: "npm:rolldown-vite@latest"' pnpm-workspace.yaml
6262
pnpm i --no-frozen-lockfile
6363
- run: pnpm -C packages/plugin-rsc exec playwright install ${{ matrix.browser }}
6464
- run: pnpm -C packages/plugin-rsc test-e2e-ci --project=${{ matrix.browser }}
@@ -67,6 +67,6 @@ jobs:
6767
- uses: actions/upload-artifact@v4
6868
if: always()
6969
with:
70-
name: test-results-${{ matrix.os }}-${{ matrix.browser }}
70+
name: test-results-${{ matrix.os }}-${{ matrix.browser }}${{ matrix.rolldown == true && '-rolldown' || '' }}
7171
path: |
7272
packages/plugin-rsc/test-results

CONTRIBUTING.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,10 @@ This repo is a monorepo using pnpm workspaces. The package manager used to insta
1313
- Checkout a topic branch from a base branch (e.g. `main`), and merge back against that branch.
1414

1515
- If adding a new feature:
16-
1716
- Add accompanying test case.
1817
- Provide a convincing reason to add this feature. Ideally, you should open a suggestion issue first, and have it approved before working on it.
1918

2019
- If fixing a bug:
21-
2220
- If you are resolving a special issue, add `(fix #xxxx[,#xxxx])` (#xxxx is the issue id) in your PR title for a better release log (e.g. `fix: update entities encoding/decoding (fix #3899)`).
2321
- Provide a detailed description of the bug in the PR. Live demo preferred.
2422
- Add appropriate test coverage if applicable.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"lint-staged": "^15.5.2",
4747
"picocolors": "^1.1.1",
4848
"playwright-chromium": "^1.53.2",
49-
"prettier": "^3.0.3",
49+
"prettier": "^3.6.2",
5050
"simple-git-hooks": "^2.13.0",
5151
"tsx": "^4.20.3",
5252
"typescript": "^5.8.3",

packages/plugin-react-oxc/build.config.ts

Lines changed: 0 additions & 14 deletions
This file was deleted.

packages/plugin-react-oxc/package.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@
2020
"dist"
2121
],
2222
"type": "module",
23-
"types": "./dist/index.d.mts",
24-
"exports": "./dist/index.mjs",
23+
"types": "./dist/index.d.ts",
24+
"exports": "./dist/index.js",
2525
"scripts": {
26-
"dev": "unbuild --stub",
27-
"build": "unbuild && tsx scripts/copyRefreshRuntime.ts",
26+
"dev": "tsdown --watch",
27+
"build": "tsdown",
2828
"prepublishOnly": "npm run build"
2929
},
3030
"engines": {
@@ -44,6 +44,7 @@
4444
},
4545
"devDependencies": {
4646
"@vitejs/react-common": "workspace:*",
47+
"tsdown": "^0.12.9",
4748
"unbuild": "^3.5.0",
4849
"vite": "catalog:rolldown-vite"
4950
},

packages/plugin-react-oxc/scripts/copyRefreshRuntime.ts

Lines changed: 0 additions & 6 deletions
This file was deleted.

packages/plugin-react-oxc/src/build.d.ts

Lines changed: 0 additions & 7 deletions
This file was deleted.

packages/plugin-react-oxc/src/index.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,7 @@ import {
1212
import { exactRegex } from '@rolldown/pluginutils'
1313

1414
const _dirname = dirname(fileURLToPath(import.meta.url))
15-
16-
const refreshRuntimePath = globalThis.__IS_BUILD__
17-
? join(_dirname, 'refresh-runtime.js')
18-
: // eslint-disable-next-line n/no-unsupported-features/node-builtins -- only used in dev
19-
fileURLToPath(import.meta.resolve('@vitejs/react-common/refresh-runtime'))
15+
const refreshRuntimePath = join(_dirname, 'refresh-runtime.js')
2016

2117
export interface Options {
2218
include?: string | RegExp | Array<string | RegExp>

packages/plugin-react-oxc/tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"include": ["src", "scripts"],
2+
"include": ["src"],
33
"compilerOptions": {
44
"outDir": "dist",
55
"target": "ES2020",
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { defineConfig } from 'tsdown'
2+
3+
export default defineConfig({
4+
entry: 'src/index.ts',
5+
copy: [
6+
{
7+
from: 'node_modules/@vitejs/react-common/refresh-runtime.js',
8+
to: 'dist/refresh-runtime.js',
9+
},
10+
],
11+
})

0 commit comments

Comments
 (0)