|
|
@ -1,13 +1,13 @@ |
|
|
|
{ |
|
|
|
"scripts": { |
|
|
|
"test": "xo && ava && npm run build", |
|
|
|
"test": "xo && BABEL_ENV=testing ava && npm run build", |
|
|
|
"build": "webpack", |
|
|
|
"watch": "webpack --watch", |
|
|
|
"watch:sourcemap": "webpack --watch --devtool eval-cheap-module-source-map", |
|
|
|
"reduce-size": "babel --out-dir . --no-comments extension/*.js", |
|
|
|
"reduce-size": "BABEL_ENV=production babel --out-dir . extension/content.js", |
|
|
|
"release:amo": "cd extension && webext submit", |
|
|
|
"release:cws": "cd extension && webstore upload --auto-publish", |
|
|
|
"release": "run-s build update-version release:* reduce-size", |
|
|
|
"release": "BABEL_ENV=production run-s build reduce-size update-version release:*", |
|
|
|
"update-version": "dot-json extension/manifest.json version $(date -u +%y.%-m.%-d.%-H%M)" |
|
|
|
}, |
|
|
|
"dependencies": { |
|
|
@ -31,7 +31,6 @@ |
|
|
|
"babel-cli": "^6.24.1", |
|
|
|
"babel-core": "^6.25.0", |
|
|
|
"babel-loader": "^7.1.1", |
|
|
|
"babel-plugin-jsx": "^1.2.0", |
|
|
|
"babel-plugin-transform-es2015-modules-commonjs": "^6.24.1", |
|
|
|
"babel-plugin-transform-react-jsx": "^6.24.1", |
|
|
|
"chrome-webstore-upload-cli": "^1.0.0", |
|
|
@ -73,9 +72,7 @@ |
|
|
|
] |
|
|
|
}, |
|
|
|
"babel": { |
|
|
|
"comments": false, |
|
|
|
"plugins": [ |
|
|
|
"transform-es2015-modules-commonjs", |
|
|
|
[ |
|
|
|
"transform-react-jsx", |
|
|
|
{ |
|
|
@ -83,6 +80,29 @@ |
|
|
|
"useBuiltIns": true |
|
|
|
} |
|
|
|
] |
|
|
|
] |
|
|
|
], |
|
|
|
"env": { |
|
|
|
"testing": { |
|
|
|
"plugins": [ |
|
|
|
"transform-es2015-modules-commonjs" |
|
|
|
] |
|
|
|
}, |
|
|
|
"production": { |
|
|
|
"minified": false, |
|
|
|
"presets": [ |
|
|
|
[ |
|
|
|
"babili", |
|
|
|
{ |
|
|
|
"deadcode": { |
|
|
|
"optimizeRawSize": true |
|
|
|
}, |
|
|
|
"mangle": false, |
|
|
|
"removeConsole": false, |
|
|
|
"simplify": false |
|
|
|
} |
|
|
|
] |
|
|
|
] |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|