-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.config.js
54 lines (54 loc) · 1.72 KB
/
webpack.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
var webpack = require('webpack');
module.exports = {
//entry: './app/app.jsx',
//entry: './app/app-note.jsx',
entry: [
'script-loader!jquery/dist/jquery.min.js',
'script-loader!foundation-sites/dist/js/foundation.min.js',
'./app/app-note-nav.jsx'
],
output: {
path: __dirname,
filename: './public/bundle.js'
},
externals:{
jquery: 'jQuery'
},
plugins:[
new webpack.ProvidePlugin({
'$': 'jquery'
})
],
resolve: {
modules: [__dirname, 'node_modules'],
alias: {
reducer: __dirname + '/app/reducer/reducer.js',
store: __dirname + '/app/store-config.js',
action: __dirname + '/app/action.js',
List: __dirname + '/app/comps/list.jsx',
Note: __dirname + '/app/comps/note.jsx',
NoteForm: __dirname + '/app/comps/noteform.jsx',
Main: __dirname + '/app/comps/main.jsx',
Nav: __dirname + '/app/comps/nav.jsx',
Transaction: __dirname + '/app/comps/transaction.jsx',
Account: __dirname + '/app/comps/account.jsx',
HomePage: __dirname + '/app/comps/homepage.jsx',
SignIn: __dirname + '/app/comps/sign-in.jsx',
AccountInfo: __dirname + '/app/comps/account-info.jsx',
Notification: __dirname + '/app/comps/notification.jsx'
},
extensions: ['*','.js','.jsx']
},
module:{
rules:[
{
loader: 'babel-loader',
query: {
presets: ['react', 'es2015', 'stage-0']
},
test: /\.jsx?$/,
exclude: /node_modules/
}
]
}
};