https://github.com/lwd-technology/react-app-rewire-define-plugin
Add webpack.DefinePlugin to a react-app-rewired config.
https://github.com/lwd-technology/react-app-rewire-define-plugin
react-app-rewired webpack
Last synced: 29 days ago
JSON representation
Add webpack.DefinePlugin to a react-app-rewired config.
- Host: GitHub
- URL: https://github.com/lwd-technology/react-app-rewire-define-plugin
- Owner: lwd-technology
- License: mit
- Created: 2017-09-22T21:51:08.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-14T07:31:07.000Z (over 6 years ago)
- Last Synced: 2025-03-29T11:34:32.032Z (about 2 months ago)
- Topics: react-app-rewired, webpack
- Language: JavaScript
- Size: 33.2 KB
- Stars: 7
- Watchers: 7
- Forks: 4
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# react-app-rewire-define-plugin
Add `webpack.DefinePlugin` to a [`react-app-rewired`](https://github.com/timarney/react-app-rewired) config.
```js
const rewireDefinePlugin = require('react-app-rewire-define-plugin')// Use `webpack.DefinePlugin` to add the version number from package.json
config = rewireDefinePlugin(config, env, {
'process.env.VERSION': JSON.stringify(require('./package.json').version)
})
```