Skip to content

Format with prettier #304

Format with prettier

Format with prettier #304

Workflow file for this run

# syntax: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions
name: Browser
on:
push:
paths-ignore:
- '**.md'
- '.vscode/**'
- 'bundles/**'
- 'dev/**'
- 'readme/**'
pull_request:
paths-ignore:
- '**.md'
- '.vscode/**'
- 'bundles/**'
- 'dev/**'
- 'readme/**'
jobs:
build:
runs-on: ubuntu-latest
name: Browser
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: NodeJS
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Install
run: |
rm -f package.json
rm -f package-lock.json
npm init -y
npm i -D rimraf typescript puppeteer
npm i -D webpack webpack-cli ts-loader nyc coverage-istanbul-loader
- name: Prepare
run: |
node_modules/.bin/rimraf .nyc_output coverage
node_modules/.bin/tsc -p tsconfig.json
node_modules/.bin/tsc -p scripts/browserTest/tsconfig.json
node_modules/.bin/webpack -c webpack/webpack.bundle.instrumented.js
- name: Test
run: |
node scripts/browserTest/index.mjs --coverage
- name: Coverage
run: |
node_modules/.bin/nyc report --exclude "src/{bundles,dev,htm,ui}/**" --exclude "src/mod.ts" --reporter=text --reporter=html --reporter=lcov
- name: Upload coverage to Codecov
if: ${{ github.ref == 'refs/heads/master' }}
uses: codecov/codecov-action@v2