Socket
Socket
Sign inDemoInstall

react-app-rewire-uglifyjs

Package Overview
Dependencies
875
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    react-app-rewire-uglifyjs

Add uglifyjs-webpack-plugin to create-react-app using react-app-rewired


Version published
Weekly downloads
187
decreased by-10.1%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

react-app-rewire-uglifyjs

npm version npm downloads

create-react-app doesn't support tree-shaking because it uses webpack's builtin uglifyjs plugin. This library will replace it with uglifyjs-webpack-plugin and enable tree shaking to your cra project!

Install

$ yarn add react-app-rewire-uglifyjs --dev
or
$ npm install --only=dev react-app-rewire-uglifyjs

Add it to your project

  1. Rewire your app
  2. modify config-overrides.js
const rewireUglifyjs = require('react-app-rewire-uglifyjs');

/* config-overrides.js */
module.exports = function override(config, env) {
  config = rewireUglifyjs(config);
  return config;
}

FAQs

Last updated on 25 May 2018

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc