Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const webpack = require("webpack");
- const path = require("path");
- module.exports = {
- entry: {
- index: "vents",
- vendor: [
- "canvasjs",
- "babel-polyfill",
- "react",
- "react-dom",
- "redux",
- "react-redux",
- "react-tap-event-plugin",
- "material-ui",
- "redux-form",
- "redux-thunk",
- "prop-types",
- "whatwg-fetch",
- "reselect",
- "re-reselect"
- ]
- },
- output: {
- path: path.resolve("bin"),
- publicPath: "/js/bin/",
- filename: "[name].js"
- },
- module: {
- rules: [
- {
- test: /\.js$/,
- exclude: /node_modules/,
- loader: "babel-loader"
- },
- {
- test: /canvasjs\.min\.js$/,
- loader: "exports-loader?CanvasJS"
- }
- ]
- },
- plugins: [
- new webpack.optimize.CommonsChunkPlugin({
- names: [
- "vendor",
- "manifest"
- ]
- })
- ],
- resolve: {
- alias: {
- components: path.resolve("src", "components"),
- containers: path.resolve("src", "containers"),
- actions: path.resolve("src", "actions"),
- reducers: path.resolve("src", "reducers"),
- selectors: path.resolve("src", "selectors"),
- canvasjs: "canvasjs.min.js"
- },
- modules: [
- __dirname,
- "src",
- "node_modules"
- ]
- }
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement