UNPKG

react-highlight-words

Version:

React component to highlight words within a larger body of text

42 lines (40 loc) 852 B
const HtmlWebpackPlugin = require('html-webpack-plugin') const path = require('path') const webpack = require('webpack') module.exports = { devtool: 'eval', entry: [ 'babel/polyfill', './website/index.js' ], output: { path: 'build', filename: '/static/[name].js' }, plugins: [ new HtmlWebpackPlugin({ filename: 'index.html', inject: true, template: './website/index.html' }), new webpack.NoErrorsPlugin() ], module: { loaders: [ { test: /\.js$/, loader: 'babel', exclude: path.join(__dirname, 'node_modules') }, { test: /\.css$/, loaders: ['style', 'css?modules&importLoaders=1', 'cssnext'], exclude: path.join(__dirname, 'node_modules') } ] }, devServer: { contentBase: 'build', port: 3567 } }