Skip to content

docs: update rslib integration guide #2550

docs: update rslib integration guide

docs: update rslib integration guide #2550

Workflow file for this run

name: Test
on:
pull_request:
branches: [main]
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
env:
# Configure Node.js memory limit to 6GB (default GitHub Actions limit is 7GB)
NODE_OPTIONS: --max-old-space-size=6144
jobs:
# ======== ut ========
ut:
runs-on: ${{ matrix.os }}
timeout-minutes: 15
strategy:
matrix:
# run ut in macOS, as SWC cases will fail in Ubuntu CI
os: [macos-14, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
fetch-depth: 1
- name: Install Pnpm
run: |
npm install -g corepack@latest --force
corepack enable
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
id: changes
with:
predicate-quantifier: 'every'
filters: |
changed:
- "!**/*.md"
- "!**/*.mdx"
- "!**/_meta.json"
- "!**/dictionary.txt"
- name: Setup Node.js
if: steps.changes.outputs.changed == 'true'
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
with:
node-version: 22
cache: 'pnpm'
- name: Install Dependencies
if: steps.changes.outputs.changed == 'true'
run: pnpm install
- name: Run Type Check
if: steps.changes.outputs.changed == 'true'
run: pnpm run typecheck
- name: Install Playwright Browsers
if: steps.changes.outputs.changed == 'true'
run: npx playwright install chromium webkit
- name: Run Test
if: steps.changes.outputs.changed == 'true'
run: pnpm run test
# ======== e2e ========
e2e:
runs-on: ${{ matrix.os }}
timeout-minutes: 15
strategy:
fail-fast: false
matrix:
# run ut in macOS, as SWC cases will fail in Ubuntu CI
os: [macos-14, windows-latest]
node_version: [18, 20, 22, 24]
steps:
- name: Checkout
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
fetch-depth: 1
- name: Install Pnpm
run: |
npm install -g corepack@latest --force
corepack enable
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
id: changes
with:
predicate-quantifier: 'every'
filters: |
changed:
- "!**/*.md"
- "!**/*.mdx"
- "!**/_meta.json"
- "!**/dictionary.txt"
- name: Setup Node.js ${{ matrix.node-version }}
if: steps.changes.outputs.changed == 'true'
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
with:
node-version: ${{ matrix.node_version }}
cache: 'pnpm'
- name: Install Dependencies
if: steps.changes.outputs.changed == 'true'
run: pnpm install
- name: Install Playwright Browsers
if: steps.changes.outputs.changed == 'true'
run: npx playwright install chromium webkit
- name: E2E Test
if: steps.changes.outputs.changed == 'true'
run: pnpm run e2e
- name: VS Code Extension Test
if: steps.changes.outputs.changed == 'true'
run: pnpm run test:vscode