Skip to content

Instantly share code, notes, and snippets.

@martiuh
Last active February 10, 2017 16:47
Show Gist options
  • Save martiuh/c8d5a7881e661ebfa5573b47a81fadf0 to your computer and use it in GitHub Desktop.
Save martiuh/c8d5a7881e661ebfa5573b47a81fadf0 to your computer and use it in GitHub Desktop.
Pequeño webpack.config para utilizar en production o en desarrollo, apoyo para mi artículo en Medium
//Este es el tipo más sencillo de un webpack.config
module.exports = {
entry: './app/mainEntry.js',
output: {
path: "/public",
filename: 'bundle.js'
},
module: {
loaders:[
{
test: /\.js$/,
exclude: /node_modules/,
loader:"babel",
query:{
presets: ["react", "es2015"]
}
}
]
},
resolve: {
extensions: ['', '.js', '.jsx']
},
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment