-
-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove semver improve npm scripts activate linting on ci
- Loading branch information
Showing
5 changed files
with
17 additions
and
21 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,4 +14,5 @@ jobs: | |
test: | ||
uses: fastify/workflows/.github/workflows/plugins-ci.yml@v3 | ||
with: | ||
lint: true | ||
license-check: true |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,6 @@ ts: false | |
jsx: false | ||
flow: false | ||
coverage: true | ||
|
||
files: | ||
- test/**/*.js |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,11 @@ | ||
'use strict' | ||
|
||
const t = require('tap') | ||
const semver = require('semver') | ||
|
||
if (semver.lt(process.versions.node, '13.3.0')) { | ||
t.skip('Skip because Node version <= 13.3.0') | ||
t.end() | ||
} else { | ||
// Node v8 throw a `SyntaxError: Unexpected token import` | ||
// even if this branch is never touch in the code, | ||
// by using `eval` we can avoid this issue. | ||
// eslint-disable-next-line | ||
new Function('module', 'return import(module)')('./esm.mjs').catch((err) => { | ||
process.nextTick(() => { | ||
throw err | ||
}) | ||
// Node v8 throw a `SyntaxError: Unexpected token import` | ||
// even if this branch is never touch in the code, | ||
// by using `eval` we can avoid this issue. | ||
// eslint-disable-next-line | ||
new Function('module', 'return import(module)')('./esm.mjs').catch((err) => { | ||
process.nextTick(() => { | ||
throw err | ||
}) | ||
} | ||
}) |
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