Skip to content

Instantly share code, notes, and snippets.

@dlmanning
Created May 9, 2015 17:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dlmanning/e208e19b59143d9c6737 to your computer and use it in GitHub Desktop.
Save dlmanning/e208e19b59143d9c6737 to your computer and use it in GitHub Desktop.
My webpack config
const path = require('path');
module.exports = {
entry: './main.js',
output: {
publicPath: '/assets',
filename: 'bundle.js'
},
resolve: {
modulesDirectories: ['src', 'node_modules'],
extensions: ["", ".js", ".jsx"],
fallback: path.join(__dirname, "node_modules")
},
resolveLoader: { fallback: path.join(__dirname, "node_modules") },
module: {
loaders: [
{
test: /\.js(x)?$/,
exclude: /node_modules/,
loader: 'babel-loader',
query: {
optional: ["es7.decorators", "es7.classProperties"]
}
}
]
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment