kopia lustrzana https://github.com/OpenDroneMap/WebODM
36 wiersze
763 B
JavaScript
36 wiersze
763 B
JavaScript
var path = require("path")
|
|
var webpack = require('webpack')
|
|
var BundleTracker = require('webpack-bundle-tracker')
|
|
|
|
module.exports = {
|
|
context: __dirname,
|
|
|
|
entry: './app/static/app/js/index.jsx', // entry point of our app.
|
|
|
|
output: {
|
|
path: path.resolve('./app/static/app/bundles/'),
|
|
filename: "[name]-[hash].js",
|
|
},
|
|
|
|
plugins: [
|
|
new BundleTracker({filename: './webpack-stats.json'}),
|
|
],
|
|
|
|
module: {
|
|
loaders: [
|
|
{
|
|
test: /\.jsx?$/,
|
|
exclude: /(node_modules|bower_components)/,
|
|
loader: 'babel-loader',
|
|
query: {
|
|
presets: ['es2015', 'react']
|
|
}
|
|
}
|
|
]
|
|
},
|
|
|
|
resolve: {
|
|
modulesDirectories: ['node_modules', 'bower_components'],
|
|
extensions: ['', '.js', '.jsx']
|
|
}
|
|
} |