Structure fixes #160
Workflow file for this run
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 | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| build: | |
| name: Build | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@v5 | |
| - name: Set up Node.js 18.x | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 18.x | |
| cache: 'npm' | |
| registry-url: 'https://registry.npmjs.org/' | |
| - name: Install Dependencies | |
| run: npm ci | |
| - name: Build PlayCanvas Observer | |
| run: npm run build | |
| lint: | |
| name: Lint | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@v5 | |
| - name: Set up Node.js 18.x | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 18.x | |
| cache: 'npm' | |
| registry-url: 'https://registry.npmjs.org/' | |
| - name: Install Dependencies | |
| run: npm ci | |
| - name: Run ESLint | |
| run: npm run lint | |
| test: | |
| name: Test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@v5 | |
| - name: Set up Node.js 18.x | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 18.x | |
| cache: 'npm' | |
| registry-url: 'https://registry.npmjs.org/' | |
| - name: Install Dependencies | |
| run: npm ci | |
| - name: Build PlayCanvas Observer (ESM only) | |
| run: npm run build:esm | |
| - name: Run Tests | |
| run: npm test |