-
-
Notifications
You must be signed in to change notification settings - Fork 71
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(core): complete rewrite with Typescript and modern node APIs
use esm, TypeScript, node apis, jest and promises where possible BREAKING CHANGE: Requires Node 20.11+ and ESM fix #169 fix #129 concerns #91
- Loading branch information
Showing
190 changed files
with
9,127 additions
and
7,809 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 |
---|---|---|
@@ -1,15 +1,16 @@ | ||
# This file is automatically generated by a `metapak` | ||
# module. Do not change it elsewhere, changes would | ||
# module. Do not change it here, your changes would | ||
# be overridden. | ||
|
||
engines: | ||
eslint: | ||
enabled: true | ||
|
||
ratings: | ||
paths: | ||
- "src/*.js bin/*.js tests/*.mocha.js" | ||
- "'src/**/*.ts'" | ||
## Exclude test files. | ||
exclude_patterns: | ||
- "dist/" | ||
- "**/node_modules/" | ||
- "tests/*.mocha.js" | ||
- "src/**/*.test.ts" |
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,3 +1,2 @@ | ||
*.md text eol=lf | ||
*.html text eol=lf | ||
*.js text eol=lf | ||
# Enforce Unix newlines | ||
* text=auto eol=lf |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
github: [nfroidure] |
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,35 +1,31 @@ | ||
# This file is automatically generated by a `metapak` | ||
# module. Do not change it here, your changes would | ||
# be overridden. | ||
|
||
name: Node.js CI | ||
|
||
on: | ||
push: | ||
branches-ignore: | ||
- "dependabot/**" | ||
branches: [main] | ||
pull_request: | ||
workflow_dispatch: | ||
name: Run tests | ||
branches: [main] | ||
|
||
jobs: | ||
test: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
node: [12, 14, 16, 18] | ||
node-version: [20.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
- uses: actions/checkout@v4 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node }} | ||
cache: npm | ||
- run: npm ci | ||
- run: npm test | ||
- uses: coverallsapp/github-action@master | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
flag-name: run-${{ matrix.node }} | ||
parallel: true | ||
finish: | ||
needs: test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: coverallsapp/github-action@master | ||
with: | ||
github-token: ${{ secrets.github_token }} | ||
parallel-finished: true | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'npm' | ||
- name: Install dependencies | ||
run: npm ci | ||
- name: Run pre-commit tests | ||
run: npm run precz |
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 |
---|---|---|
|
@@ -129,4 +129,5 @@ Temporary Items | |
.coveralls.yml | ||
|
||
# Project custom ignored file | ||
tests/results | ||
dist | ||
src/tests/results |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"recommendations": [ | ||
"dbaeumer.vscode-eslint", | ||
"esbenp.prettier-vscode", | ||
"gruntfuggly.todo-tree" | ||
] | ||
} |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"typescript.tsdk": "node_modules/typescript/lib" | ||
} |
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
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 |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// @ts-check | ||
// This file is automatically generated by a `metapak` | ||
// module. Do not change it elsewhere, changes would | ||
// be overridden. | ||
|
||
import eslint from '@eslint/js'; | ||
import tseslint from 'typescript-eslint'; | ||
import eslintConfigPrettier from 'eslint-config-prettier'; | ||
import eslintPluginJest from 'eslint-plugin-jest'; | ||
|
||
export default tseslint.config( | ||
eslint.configs.recommended, | ||
...tseslint.configs.recommended, | ||
{ | ||
files: ['*.test.ts'], | ||
...eslintPluginJest.configs['flat/recommended'], | ||
}, | ||
eslintConfigPrettier, | ||
{ | ||
name: 'Project config', | ||
languageOptions: { | ||
ecmaVersion: 2018, | ||
sourceType: 'module', | ||
}, | ||
ignores: ['*.d.ts'], | ||
}, | ||
); | ||
|
Oops, something went wrong.