Skip to content

Commit

Permalink
Merge pull request #179 from hckrnews/feature/commonjs
Browse files Browse the repository at this point in the history
Add commonjs support
  • Loading branch information
w3nl authored Dec 2, 2022
2 parents d2478fb + 77805d4 commit bd5bcee
Show file tree
Hide file tree
Showing 7 changed files with 5,792 additions and 1,468 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 18
node-version: "18.10"
- run: npm ci
- run: npm test

Expand All @@ -25,7 +25,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 18
node-version: "18.10"
registry-url: https://registry.npmjs.org/
- run: npm ci
- run: npm run build --if-present
Expand Down
37 changes: 18 additions & 19 deletions .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,24 @@ on: [push]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Use Node.js 18
uses: actions/setup-node@v1
with:
node-version: 18
cache: 'npm'
- name: npm install, lint, and test
run: |
npm ci
npm run lint:report
npm test
env:
CI: true
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- uses: actions/checkout@v2
- name: Use Node.js 18
uses: actions/setup-node@v1
with:
node-version: "18.10"
cache: "npm"
- name: npm install, lint, and test
run: |
npm ci
npm run lint:report
npm test
env:
CI: true
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
27 changes: 13 additions & 14 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,22 @@ on: [push]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x]
node-version: ["18.10", 19.x]

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: npm test
run: |
npm ci
npm test
env:
CI: true
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
- name: npm test
run: |
npm ci
npm test
env:
CI: true
1 change: 1 addition & 0 deletions .nyc_output/processinfo/index.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"processes":{"786c1cfd-3856-4be0-82b7-1cfd4ac1be94":{"parent":null,"children":[]}},"files":{},"externalIds":{}}
1 change: 0 additions & 1 deletion babel.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,4 @@ module.exports = {
},
],
],
plugins: ['@babel/plugin-transform-modules-commonjs'],
};
Loading

0 comments on commit bd5bcee

Please sign in to comment.