react-graceful-unmount
Version:
A higher order component to make sure the react component passed as argument always unmounts properly, even if React does not have the time to call componentWillUnmount function.
25 lines (20 loc) • 390 B
JavaScript
const webpack = require('webpack');
const path = require('path');
const config = {
entry: path.resolve('main.js'),
output: {
path: path.resolve('dist'),
filename: 'bundle.js',
library: 'withGracefulUnmount',
libraryTarget: 'umd'
},
module: {
rules: [
{
test: /.js$/,
loader: 'babel-loader'
}
]
}
};
module.exports = config;