Fix yarn watch (#587)
* Fix yarn watch * Wtach-only config * --mode development for watch * build:ui
This commit is contained in:
+3
-2
@@ -20,9 +20,10 @@
|
||||
},
|
||||
"scripts": {
|
||||
"build": "polkadot-dev-build-ts && yarn build:zip",
|
||||
"build:extra": "yarn build:i18n && (cd packages/extension && yarn webpack --config webpack.extension.js)",
|
||||
"build:extra": "yarn build:i18n && yarn build:ui",
|
||||
"build:i18n": "i18next-scanner --config i18next-scanner.config.js",
|
||||
"build:release": "polkadot-ci-ghact-build",
|
||||
"build:ui": "cd packages/extension && yarn webpack --config webpack.extension.js --mode production",
|
||||
"build:zip": "yarn build:zip:dst && yarn build:zip:src",
|
||||
"build:zip:dst": "rm -rf ./master-build.zip && cd packages/extension/build && zip -r -FS ../../../master-build.zip .",
|
||||
"build:zip:src": "rm -rf ./master-src.zip && zip -r -x '*build/*' -x '*node_modules*' -FS ./master-src.zip packages .babelrc.js .editorconfig .eslintignore .eslintrc.js babel.config.js CHANGELOG.md CONTRIBUTING.md i18next-scanner.config.js jest.config.js lerna.json LICENSE package.json README.md tsconfig.json yarn.lock",
|
||||
@@ -32,7 +33,7 @@
|
||||
"postinstall": "polkadot-dev-yarn-only",
|
||||
"start": "yarn watch",
|
||||
"test": "polkadot-dev-run-test",
|
||||
"watch": "cd packages/extension && yarn polkadot-exec-webpack --config webpack.config.js --watch"
|
||||
"watch": "cd packages/extension && yarn polkadot-exec-webpack --config webpack.watch.js --mode development --watch"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.12.10",
|
||||
|
||||
@@ -22,7 +22,6 @@ module.exports = (entry, alias = {}) => ({
|
||||
context: __dirname,
|
||||
devtool: false,
|
||||
entry,
|
||||
mode: 'production',
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
// Copyright 2019-2020 @polkadot/extension authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
const createConfig = require('./webpack.shared.js');
|
||||
|
||||
module.exports = createConfig({
|
||||
background: './src/background.ts',
|
||||
content: './src/content.ts',
|
||||
extension: './src/extension.ts',
|
||||
page: './src/page.ts'
|
||||
});
|
||||
Reference in New Issue
Block a user