Created
July 17, 2017 10:54
-
-
Save Chalarangelo/c0a492e3e96f38455c3a5f00e06ad020 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"scripts": { | |
"start": "react-scripts start", | |
"build": "react-scripts build && npm run build-rename-replace && npm run build-sw", | |
"test": "react-scripts test --env=jsdom", | |
"eject": "react-scripts eject", | |
"build-sw" : "npm run build-replace-sw-refs && npm run build-minify-sw", | |
"build-rename-replace": "npm run build-rename && npm run build-replace", | |
"build-rename": "npm run build-rename-js && npm run build-rename-css", | |
"build-rename-js": "renamer --regex --find main\\.\\w+\\.js --replace main.js build/static/js/*.js", | |
"build-rename-css": "renamer --regex --find main\\.\\w+\\.css --replace main.css build/static/css/*.css", | |
"build-replace": "npm run build-replace-js && npm run build-replace-css", | |
"build-replace-js": "replace main\\.\\w+\\.js main.js build/index.html", | |
"build-replace-css": "replace main\\.\\w+\\.css main.css build/index.html", | |
"build-replace-sw-refs": "replace './static/js/bundle.js' './static/js/main.js','./static/css/main.css' build/service-worker.js", | |
"build-minify-sw" : "uglifyjs build/service-worker.js --output build/service-worker.js" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment