Skip to content

Commit 73cb9e7

Browse files
committed
upgrade the dependencies. drop v12 support
1 parent 3979c91 commit 73cb9e7

File tree

9 files changed

+2784
-3910
lines changed

9 files changed

+2784
-3910
lines changed

.babelrc

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
11
{
2-
"presets": [
3-
["@babel/preset-env", { "targets": { "node": "12" } }]
4-
]
2+
"presets": [["@babel/preset-env", { "targets": { "node": "14" } }]]
53
}

.husky/pre-commit

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/usr/bin/env sh
2+
. "$(dirname -- "$0")/_/husky.sh"
3+
4+
npx lint-staged

.huskyrc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# ~/.huskyrc
2+
# This loads nvm.sh and sets the correct PATH before running hook
3+
export NVM_DIR="$HOME/.nvm"
4+
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"

.lintstagedrc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"*.{js}": [
3+
"eslint --quiet --fix"
4+
],
5+
"*.{json,md,html}": [
6+
"prettier --write"
7+
]
8+
}

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
14.19

.travis.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
language: node_js
22
node_js:
3-
- 12
4-
- 10
3+
- 14
4+
- 16
5+
- 18
56
script:
67
- jest --ci --coverage && codecov

package.json

Lines changed: 23 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -10,59 +10,50 @@
1010
"scripts": {
1111
"clean": "rimraf coverage dist",
1212
"build": "rollup -c",
13-
"lint": "eslint src tests",
13+
"lint": "eslint *.js",
14+
"format": "prettier --write .",
15+
"lint:staged": "lint-staged",
1416
"postpublish": "yarn clean",
1517
"prepublishOnly": "yarn lint && yarn test && yarn clean && yarn build",
16-
"test": "jest"
18+
"test": "jest",
19+
"postinstall": "is-ci || husky install"
1720
},
1821
"dependencies": {
19-
"@types/fs-extra": "^8.0.1",
20-
"colorette": "^1.1.0",
21-
"fs-extra": "^9.0.0",
22-
"globby": "10.0.1",
23-
"is-plain-object": "^3.0.0"
22+
"@types/fs-extra": "^9.0.13",
23+
"colorette": "^2.0.17",
24+
"fs-extra": "^10.1.0",
25+
"globby": "13.1.1",
26+
"is-plain-object": "^5.0.0"
2427
},
2528
"devDependencies": {
2629
"@babel/core": "^7.8.3",
2730
"@babel/preset-env": "^7.8.3",
28-
"babel-jest": "^24.9.0",
31+
"@rollup/plugin-babel": "^5.3.1",
32+
"babel-jest": "^28.1.0",
2933
"codecov": "^3.6.1",
30-
"eslint": "^7.15.0",
31-
"eslint-config-airbnb-base": "^14.2.1",
32-
"eslint-config-prettier": "^7.0.0",
34+
"eslint": "^8.17.0",
35+
"eslint-config-airbnb-base": "^15.0.0",
36+
"eslint-config-prettier": "^8.5.0",
3337
"eslint-plugin-import": "^2.22.1",
34-
"eslint-plugin-prettier": "^3.3.0",
35-
"husky": "^4.3.6",
36-
"jest": "^24.9.0",
37-
"lint-staged": "^10.5.3",
38+
"eslint-plugin-prettier": "^4.0.0",
39+
"husky": "^8.0.0",
40+
"is-ci": "^3.0.1",
41+
"jest": "^28.1.0",
42+
"lint-staged": "^13.0.0",
3843
"prettier": "^2.2.1",
39-
"replace-in-file": "^5.0.2",
44+
"replace-in-file": "^6.3.5",
4045
"rimraf": "^3.0.0",
41-
"rollup": "^1.29.0",
46+
"rollup": "^2.75.5",
4247
"rollup-plugin-auto-external": "^2.0.0",
43-
"rollup-plugin-babel": "^4.3.3",
4448
"rollup-plugin-includepaths": "^0.2.4"
4549
},
4650
"files": [
4751
"dist",
4852
"index.d.ts",
4953
"readme.md"
5054
],
51-
"husky": {
52-
"hooks": {
53-
"pre-commit": "lint-staged"
54-
}
55-
},
56-
"lint-staged": {
57-
"*.{js,ts,tsx}": [
58-
"eslint --quiet --fix"
59-
],
60-
"*.{json,md,html}": [
61-
"prettier --write"
62-
]
63-
},
6455
"engines": {
65-
"node": ">=10.12"
56+
"node": ">=14"
6657
},
6758
"keywords": [
6859
"rollup",

rollup.config.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import babel from 'rollup-plugin-babel'
2-
import autoExternal from 'rollup-plugin-auto-external'
3-
import includePaths from 'rollup-plugin-includepaths'
1+
import babel from '@rollup/plugin-babel';
2+
import autoExternal from 'rollup-plugin-auto-external';
3+
import includePaths from 'rollup-plugin-includepaths';
44

55
export default {
66
input: 'src/index.js',
@@ -20,11 +20,11 @@ export default {
2020
paths: ['src'],
2121
external: [],
2222
extensions: ['.js']
23-
}),
23+
}),
2424
babel({
2525
presets: [['@babel/preset-env', { targets: { node: '8.3' } }]],
2626
comments: false
2727
}),
2828
autoExternal()
2929
]
30-
}
30+
};

0 commit comments

Comments
 (0)