fix(rsc): fix FOUC of lazy component css within client boundary #546
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ci-rsc | |
| permissions: {} | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| paths: | |
| - "packages/plugin-rsc/**" | |
| - "pnpm-lock.yaml" | |
| - ".github/workflows/ci-rsc.yml" | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.number || github.sha }} | |
| cancel-in-progress: true | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0 | |
| - run: pnpm i | |
| - run: pnpm build | |
| - run: pnpm -C packages/plugin-rsc tsc | |
| - run: pnpm -C packages/plugin-rsc test | |
| test-e2e: | |
| name: test-rsc (${{ matrix.os }} / ${{ matrix.browser }}) ${{ matrix.rolldown == true && '(rolldown)' || '' }} ${{ matrix.react_version && format('(react-{0})', matrix.react_version) || '' }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| browser: [chromium] | |
| rolldown: [false] | |
| react_version: [""] | |
| include: | |
| - os: ubuntu-latest | |
| browser: firefox | |
| - os: macos-latest | |
| browser: webkit | |
| - os: ubuntu-latest | |
| browser: chromium | |
| rolldown: true | |
| - os: ubuntu-latest | |
| browser: chromium | |
| react_version: canary | |
| - os: ubuntu-latest | |
| browser: chromium | |
| react_version: experimental | |
| fail-fast: false | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0 | |
| - run: pnpm i | |
| - name: install react | |
| if: ${{ matrix.react_version }} | |
| run: | | |
| sed -i "/^overrides:/a\ react: \"${{ matrix.react_version }}\"" pnpm-workspace.yaml | |
| sed -i "/^overrides:/a\ react-dom: \"${{ matrix.react_version }}\"" pnpm-workspace.yaml | |
| sed -i "/^overrides:/a\ react-server-dom-webpack: \"${{ matrix.react_version }}\"" pnpm-workspace.yaml | |
| pnpm i --no-frozen-lockfile | |
| - run: pnpm build | |
| - name: install rolldown | |
| if: ${{ matrix.rolldown }} | |
| run: | | |
| sed -i '/^overrides:/a\ vite: "npm:rolldown-vite@latest"' pnpm-workspace.yaml | |
| pnpm i --no-frozen-lockfile | |
| - run: pnpm -C packages/plugin-rsc exec playwright install ${{ matrix.browser }} | |
| - run: pnpm -C packages/plugin-rsc test-e2e-ci --project=${{ matrix.browser }} | |
| - uses: actions/upload-artifact@v4 | |
| if: always() | |
| with: | |
| name: test-results-${{ matrix.os }}-${{ matrix.browser }}${{ matrix.rolldown == true && '-rolldown' || '' }}${{ matrix.react_version && format('-react-{0}', matrix.react_version) || '' }} | |
| path: | | |
| packages/plugin-rsc/test-results |