Add style-src 'self' 'unsafe-inline' to CSP #343
Workflow file for this run
This file contains 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: Node.js CI | |
on: [push, pull_request] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./ | |
strategy: | |
fail-fast: false | |
matrix: | |
test-case: [ | |
# Lowest supported versions are 1.21.0 for Rollup and 4.0.1 for Webpack. | |
{ node: 14.x, rollup: 1.21.0, webpack: 4.0.1 }, | |
{ node: 14.x, rollup: ^1.21.0, webpack: ^4.0.1 }, | |
{ node: 14.x, rollup: ^2.0.0, webpack: 5.0.x }, | |
{ node: 14.x, rollup: ^3.0.0, webpack: ^5.0.0 }, | |
{ node: 16.x, rollup: 1.21.x, webpack: 4.1.x }, | |
{ node: 16.x, rollup: ^1.21.0, webpack: ^4.0.1 }, | |
{ node: 16.x, rollup: ^2.0.0, webpack: 5.0.x }, | |
{ node: 16.x, rollup: ^3.0.0, webpack: ^5.0.0 }, | |
# Node 18 only works with Webpack version ^5.61.x. | |
{ node: 18.x, rollup: 1.21.x, webpack: 5.61.x }, | |
{ node: 18.x, rollup: ^1.21.0, webpack: ^5.0.0 }, | |
{ node: 18.x, rollup: ^2.0.0, webpack: 5.61.x }, | |
{ node: 18.x, rollup: ^3.0.0, webpack: ^5.0.0 }, | |
] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js ${{ matrix.test-case.node }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.test-case.node }} | |
cache: 'npm' | |
# Underlying wbn-sign requires to use npm v8+ | |
- run: npm install -g npm@8 | |
- name: Install deps | |
run: npm ci | |
- name: Uninstall old versions of Webpack | |
run: npm uninstall -D @types/webpack webpack | |
working-directory: ./packages/webbundle-webpack-plugin | |
- name: Uninstall old versions of Rollup | |
run: npm uninstall -D rollup | |
working-directory: ./packages/rollup-plugin-webbundle | |
- name: Install Rollup v${{ matrix.test-case.rollup }} | |
run: npm install --save-dev rollup@${{ matrix.test-case.rollup }} | |
working-directory: ./packages/rollup-plugin-webbundle | |
- name: Install Webpack v${{ matrix.test-case.webpack }} | |
run: npm install --save-dev webpack@${{ matrix.test-case.webpack }} @types/webpack | |
working-directory: ./packages/webbundle-webpack-plugin | |
- run: npm run build | |
- run: npm run test | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js 18.x | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18.x | |
cache: 'npm' | |
- run: npm ci | |
- run: npm run lint |