Skip to content

Commit f31db7c

Browse files
committed
build: perfomance build system
1 parent dfd480d commit f31db7c

File tree

1 file changed

+42
-28
lines changed

1 file changed

+42
-28
lines changed

package.json

Lines changed: 42 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,11 @@
1616
"node": ">=4"
1717
},
1818
"scripts": {
19-
"commitmsg": "conventional-changelog-lint -e",
20-
"postpublish": "conventional-changelog -i changelog.md -s -r 0 && git commit -am \"chore(changelog): Update changelog\"",
21-
"patch": "np patch --any-branch",
22-
"minor": "np minor --any-branch",
23-
"major": "np major --any-branch",
19+
"precommit": "clinton && lint-staged",
20+
"commitmsg": "commitlint --extends=@commitlint/config-angular -e",
21+
"postpublish": "conventional-changelog -i changelog.md -s -r 0 && git commit -am \"build: update changelog\"",
22+
"prepare": "npm run build",
2423
"build": "rimraf lib && babel src -d lib",
25-
"prepublish": "npm run build",
26-
"lintjs": "eslint ./{src,test}/*.js",
27-
"lintmd": "eslint --ext md --rule indent: [error, 4] .",
28-
"pretest": "clinton && npm run lintjs && npm run lintmd",
2924
"test": "nyc ava"
3025
},
3126
"files": [
@@ -48,64 +43,83 @@
4843
"postcss": "^6.0.1"
4944
},
5045
"devDependencies": {
46+
"@commitlint/cli": "^5.2.0",
47+
"@commitlint/config-angular": "^5.1.1",
5148
"ava": "*",
5249
"babel-cli": "^6.24.1",
5350
"babel-eslint": "^8.0.3",
5451
"babel-plugin-add-module-exports": "^0.2.1",
55-
"babel-preset-babili": "^0.1.4",
5652
"babel-preset-env": "^1.3.2",
53+
"babel-preset-minify": "^0.2.0",
5754
"babel-register": "^6.24.1",
5855
"clinton": "^0.13.0",
5956
"conventional-changelog-cli": "^1.3.1",
60-
"conventional-changelog-lint": "^2.1.1",
6157
"coveralls": "^3.0.0",
6258
"eslint": "^4.12.0",
6359
"eslint-config-xo": "^0.19.0",
6460
"eslint-formatter-pretty": "^1.1.0",
6561
"eslint-plugin-ava": "^4.0.1",
6662
"eslint-plugin-babel": "^4.0.1",
67-
"eslint-plugin-markdown": "^1.0.0-beta.4",
68-
"eslint-plugin-xo": "^1.0.0",
63+
"eslint-plugin-markdown": "^1.0.0-beta.7",
64+
"eslint-plugin-unicorn": "^3.0.0",
6965
"husky": "^0.14.3",
70-
"np": "^2.14.1",
66+
"lint-staged": "^6.0.0",
7167
"nyc": "^11.3.0",
7268
"rimraf": "^2.6.1"
7369
},
70+
"lint-staged": {
71+
"*.{js,html}": "eslint",
72+
"./*.md": "eslint --rule indent: [error, 4] ."
73+
},
74+
"ava": {
75+
"require": [
76+
"babel-register"
77+
]
78+
},
7479
"babel": {
7580
"presets": [
7681
[
7782
"env",
7883
{
7984
"targets": {
8085
"node": 4
81-
}
86+
},
87+
"useBuiltIns": true
8288
}
8389
],
84-
"babili"
90+
[
91+
"minify",
92+
{
93+
"mangle": false
94+
}
95+
]
8596
],
8697
"plugins": [
8798
"add-module-exports"
8899
]
89100
},
90-
"ava": {
91-
"require": [
92-
"babel-register"
93-
]
94-
},
95101
"eslintConfig": {
96-
"format": "node_modules/eslint-formatter-pretty",
97102
"parser": "babel-eslint",
98103
"plugins": [
99-
"ava",
100-
"xo",
104+
"html",
105+
"unicorn",
101106
"babel",
102107
"markdown"
103108
],
104109
"extends": [
105-
"xo",
106-
"plugin:xo/recommended",
107-
"plugin:ava/recommended"
108-
]
110+
"plugin:unicorn/recommended",
111+
"xo"
112+
],
113+
"rules": {
114+
"indent": [
115+
2,
116+
4,
117+
{
118+
"SwitchCase": 1
119+
}
120+
],
121+
"capitalized-comments": "off"
122+
}
109123
},
110124
"clinton": {
111125
"ignores": [

0 commit comments

Comments
 (0)