Skip to content

feat(2d): make Code not experimental #1232

feat(2d): make Code not experimental

feat(2d): make Code not experimental #1232

Workflow file for this run

name: Verify Pull Request
on:
pull_request: {}
workflow_dispatch: {}
env:
HUSKY: 0
jobs:
prepare:
name: Prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- run: PUPPETEER_PRODUCT=firefox npm ci
- uses: actions/cache/save@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
commit:
name: Commit name
needs: prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- run: npx commitlint --from ${{ github.event.pull_request.base.sha }} --verbose
lint:
name: Lint
needs: prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- run: npm run eslint
prettier:
name: Code style
needs: prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- run: npm run prettier
build:
name: Build
needs: prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- run: npx lerna run build
- uses: actions/cache/save@v3
with:
key: ${{ github.run_id }}-build
path: |
packages/2d/lib
packages/2d/editor
packages/core/lib
packages/ui/dist
packages/player/dist
packages/vite-plugin/lib
tests:
name: Unit tests
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-build
path: |
packages/2d/lib
packages/2d/editor
packages/core/lib
packages/ui/dist
packages/player/dist
packages/vite-plugin/lib
- run: npx lerna run test
examples:
name: Examples
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-build
path: |
packages/2d/lib
packages/2d/editor
packages/core/lib
packages/ui/dist
packages/player/dist
packages/vite-plugin/lib
- run: npm run examples:build
e2e:
name: E2E
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-build
path: |
packages/2d/lib
packages/2d/editor
packages/core/lib
packages/ui/dist
packages/player/dist
packages/vite-plugin/lib
- run: npm run e2e:test
- uses: actions/upload-artifact@v3
if: failure()
with:
name: image-diffs
path: packages/e2e/src/__image_snapshots__/__diff_output__
docs:
name: Documentation
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-node-modules
path: |
**/node_modules
~/.cache/puppeteer
- uses: actions/cache/restore@v3
with:
key: ${{ github.run_id }}-build
path: |
packages/2d/lib
packages/2d/editor
packages/core/lib
packages/ui/dist
packages/player/dist
packages/vite-plugin/lib
- run: npx lerna run bundle
- run: npm run docs:build
env:
NODE_OPTIONS: "--max-old-space-size=8192"