Skip to content

Commit 439d3bb

Browse files
committed
Format with Prettier
1 parent 4232270 commit 439d3bb

File tree

9 files changed

+3698
-3638
lines changed

9 files changed

+3698
-3638
lines changed

.eslintrc.js

Lines changed: 85 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -1,90 +1,90 @@
11
/*eslint-env node*/
22
/*eslint no-console:0*/
3-
"use strict";
3+
'use strict';
44

55
module.exports = {
6-
extends: "eslint:recommended",
7-
rules: {
8-
"valid-jsdoc": ["warn", { requireReturn: false }],
9-
"accessor-pairs": "warn",
10-
"array-callback-return": "warn",
11-
"block-scoped-var": "warn",
12-
complexity: ["warn", { max: 25 }],
13-
"consistent-return": "warn",
14-
"default-case": "warn",
15-
"dot-notation": "warn",
16-
eqeqeq: ["warn", "allow-null"],
17-
"guard-for-in": "warn",
18-
"no-alert": "warn",
19-
"no-caller": "error",
20-
"no-div-regex": "warn",
21-
"no-else-return": "warn",
22-
"no-empty-function": "warn",
23-
"no-eval": "error",
24-
"no-extend-native": "warn",
25-
"no-extra-bind": "warn",
26-
"no-extra-label": "warn",
27-
"no-floating-decimal": "warn",
28-
"no-implicit-coercion": "warn",
29-
"no-implicit-globals": "warn",
30-
"no-implied-eval": "error",
31-
"no-iterator": "error",
32-
"no-labels": "warn",
33-
"no-lone-blocks": "warn",
34-
"no-loop-func": "error",
35-
"no-magic-numbers": ["warn", { ignore: [-1, 0, 1] }],
36-
"no-multi-str": "warn",
37-
"no-native-reassign": "error",
38-
"no-new": "warn",
39-
"no-new-func": "error",
40-
"no-new-wrappers": "warn",
41-
"no-octal-escape": "error",
42-
"no-proto": "warn",
43-
"no-return-assign": "error",
44-
"no-script-url": "warn",
45-
"no-self-compare": "error",
46-
"no-sequences": "warn",
47-
"no-throw-literal": "warn",
48-
"no-unmodified-loop-condition": "warn",
49-
"no-unused-expressions": "error",
50-
"no-unsafe-finally": "error",
51-
"no-useless-call": "warn",
52-
"no-useless-computed-key": "warn",
53-
"no-useless-concat": "warn",
54-
"no-warning-comments": [
55-
"warn",
56-
{ terms: ["todo", "bug"], location: "start" }
57-
],
58-
"no-with": "error",
59-
radix: "warn",
60-
yoda: "warn",
61-
strict: ["warn", "safe"],
62-
"no-catch-shadow": "error",
63-
"no-restricted-globals": ["warn", "event"],
64-
"no-shadow": "warn",
65-
"no-shadow-restricted-names": "error",
66-
"no-undef": "error",
67-
"no-use-before-define": "error",
68-
"no-useless-constructor": "warn",
69-
"no-var": "warn",
70-
"object-shorthand": "warn",
71-
"prefer-arrow-callback": "warn",
72-
"prefer-const": "warn",
73-
"prefer-rest-params": "warn",
74-
"prefer-spread": "warn",
75-
"prefer-template": "warn",
76-
"require-yield": "warn",
77-
"no-duplicate-imports": "warn",
78-
"max-statements-per-line": ["warn", { max: 2 }],
79-
"no-useless-escape": "warn"
80-
},
81-
env: {
82-
node: true,
83-
es6: true
84-
},
85-
parserOptions: {
86-
ecmaVersion: 6,
87-
sourceType: "module"
88-
},
89-
root: true
6+
extends: 'eslint:recommended',
7+
rules: {
8+
'valid-jsdoc': ['warn', { requireReturn: false }],
9+
'accessor-pairs': 'warn',
10+
'array-callback-return': 'warn',
11+
'block-scoped-var': 'warn',
12+
complexity: ['warn', { max: 25 }],
13+
'consistent-return': 'warn',
14+
'default-case': 'warn',
15+
'dot-notation': 'warn',
16+
eqeqeq: ['warn', 'allow-null'],
17+
'guard-for-in': 'warn',
18+
'no-alert': 'warn',
19+
'no-caller': 'error',
20+
'no-div-regex': 'warn',
21+
'no-else-return': 'warn',
22+
'no-empty-function': 'warn',
23+
'no-eval': 'error',
24+
'no-extend-native': 'warn',
25+
'no-extra-bind': 'warn',
26+
'no-extra-label': 'warn',
27+
'no-floating-decimal': 'warn',
28+
'no-implicit-coercion': 'warn',
29+
'no-implicit-globals': 'warn',
30+
'no-implied-eval': 'error',
31+
'no-iterator': 'error',
32+
'no-labels': 'warn',
33+
'no-lone-blocks': 'warn',
34+
'no-loop-func': 'error',
35+
'no-magic-numbers': ['warn', { ignore: [-1, 0, 1] }],
36+
'no-multi-str': 'warn',
37+
'no-native-reassign': 'error',
38+
'no-new': 'warn',
39+
'no-new-func': 'error',
40+
'no-new-wrappers': 'warn',
41+
'no-octal-escape': 'error',
42+
'no-proto': 'warn',
43+
'no-return-assign': 'error',
44+
'no-script-url': 'warn',
45+
'no-self-compare': 'error',
46+
'no-sequences': 'warn',
47+
'no-throw-literal': 'warn',
48+
'no-unmodified-loop-condition': 'warn',
49+
'no-unused-expressions': 'error',
50+
'no-unsafe-finally': 'error',
51+
'no-useless-call': 'warn',
52+
'no-useless-computed-key': 'warn',
53+
'no-useless-concat': 'warn',
54+
'no-warning-comments': [
55+
'warn',
56+
{ terms: ['todo', 'bug'], location: 'start' },
57+
],
58+
'no-with': 'error',
59+
radix: 'warn',
60+
yoda: 'warn',
61+
strict: ['warn', 'safe'],
62+
'no-catch-shadow': 'error',
63+
'no-restricted-globals': ['warn', 'event'],
64+
'no-shadow': 'warn',
65+
'no-shadow-restricted-names': 'error',
66+
'no-undef': 'error',
67+
'no-use-before-define': 'error',
68+
'no-useless-constructor': 'warn',
69+
'no-var': 'warn',
70+
'object-shorthand': 'warn',
71+
'prefer-arrow-callback': 'warn',
72+
'prefer-const': 'warn',
73+
'prefer-rest-params': 'warn',
74+
'prefer-spread': 'warn',
75+
'prefer-template': 'warn',
76+
'require-yield': 'warn',
77+
'no-duplicate-imports': 'warn',
78+
'max-statements-per-line': ['warn', { max: 2 }],
79+
'no-useless-escape': 'warn',
80+
},
81+
env: {
82+
node: true,
83+
es6: true,
84+
},
85+
parserOptions: {
86+
ecmaVersion: 6,
87+
sourceType: 'module',
88+
},
89+
root: true,
9090
};

.github/dependabot.yml

Lines changed: 23 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,23 @@
1-
version: 2
2-
updates:
3-
- package-ecosystem: npm
4-
directory: "/"
5-
schedule:
6-
interval: daily
7-
time: "07:00"
8-
timezone: "America/Chicago"
9-
- package-ecosystem: github-actions
10-
directory: "/"
11-
schedule:
12-
interval: daily
13-
time: "07:00"
14-
timezone: "America/Chicago"
1+
{
2+
"version": 2,
3+
"updates": [
4+
{
5+
"package-ecosystem": "npm",
6+
"directory": "/",
7+
"schedule": {
8+
"interval": "daily",
9+
"time": "07:00",
10+
"timezone": "America/Chicago"
11+
}
12+
},
13+
{
14+
"package-ecosystem": "github-actions",
15+
"directory": "/",
16+
"schedule": {
17+
"interval": "daily",
18+
"time": "07:00",
19+
"timezone": "America/Chicago"
20+
}
21+
}
22+
]
23+
}

.github/workflows/node.js.yml

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,29 @@
1-
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
2-
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
3-
4-
name: Node.js CI
5-
6-
on:
7-
push:
8-
branches: ["master"]
9-
pull_request:
10-
branches: ["master"]
11-
12-
jobs:
13-
build:
14-
runs-on: ubuntu-latest
15-
16-
strategy:
17-
matrix:
18-
node-version: [14.x, 16.x, 18.x]
19-
20-
steps:
21-
- uses: actions/[email protected]
22-
- name: Use Node.js ${{ matrix.node-version }}
23-
uses: actions/[email protected]
24-
with:
25-
node-version: ${{ matrix.node-version }}
26-
cache: "npm"
27-
- run: npm ci
28-
- run: npm run build --if-present
29-
- run: npm test
1+
{
2+
"name": "Node.js CI",
3+
"on": {
4+
"push": { "branches": ["master"] },
5+
"pull_request": { "branches": ["master"] }
6+
},
7+
"jobs": {
8+
"build": {
9+
"runs-on": "ubuntu-latest",
10+
"strategy": {
11+
"matrix": { "node-version": ["14.x", "16.x", "18.x"] }
12+
},
13+
"steps": [
14+
{ "uses": "actions/[email protected]" },
15+
{
16+
"name": "Use Node.js ${{ matrix.node-version }}",
17+
"uses": "actions/[email protected]",
18+
"with": {
19+
"node-version": "${{ matrix.node-version }}",
20+
"cache": "npm"
21+
}
22+
},
23+
{ "run": "npm ci" },
24+
{ "run": "npm run build --if-present" },
25+
{ "run": "npm test" }
26+
]
27+
}
28+
}
29+
}

.github/workflows/npm-publish.yml

Lines changed: 41 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,41 @@
1-
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
2-
# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
3-
4-
name: Node.js Package
5-
6-
on:
7-
release:
8-
types: [created]
9-
10-
jobs:
11-
build:
12-
runs-on: ubuntu-latest
13-
steps:
14-
- uses: actions/[email protected]
15-
- uses: actions/[email protected]
16-
with:
17-
node-version: 18
18-
- run: npm ci
19-
- run: npm test
20-
21-
publish-npm:
22-
needs: build
23-
runs-on: ubuntu-latest
24-
steps:
25-
- uses: actions/[email protected]
26-
- uses: actions/[email protected]
27-
with:
28-
node-version: 18
29-
registry-url: https://registry.npmjs.org/
30-
- run: npm ci
31-
- run: npm publish
32-
env:
33-
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
1+
{
2+
"name": "Node.js Package",
3+
"on": { "release": { "types": ["created"] } },
4+
"jobs": {
5+
"build": {
6+
"runs-on": "ubuntu-latest",
7+
"steps": [
8+
{ "uses": "actions/[email protected]" },
9+
{
10+
"uses": "actions/[email protected]",
11+
"with": {
12+
"node-version": 18
13+
}
14+
},
15+
{ "run": "npm ci" },
16+
{ "run": "npm test" }
17+
]
18+
},
19+
"publish-npm": {
20+
"needs": "build",
21+
"runs-on": "ubuntu-latest",
22+
"steps": [
23+
{ "uses": "actions/[email protected]" },
24+
{
25+
"uses": "actions/[email protected]",
26+
"with": {
27+
"node-version": 18,
28+
"registry-url": "https://registry.npmjs.org/"
29+
}
30+
},
31+
{ "run": "npm ci" },
32+
{
33+
"run": "npm publish",
34+
"env": {
35+
"NODE_AUTH_TOKEN": "${{secrets.npm_token}}"
36+
}
37+
}
38+
]
39+
}
40+
}
41+
}

0 commit comments

Comments
 (0)