]>
Commit | Line | Data |
---|---|---|
f9d1a6b3 | 1 | var path = require('path'); |
2 | ||
1983893b | 3 | var srcs = ['src[]=bower_components/purescript-*/src/**/*.purs', 'src[]=src/**/*.purs']; |
4 | ||
5 | var ffis = ['ffi[]=bower_components/purescript-*/src/**/*.js']; | |
6 | ||
7 | var output = 'output'; | |
8 | ||
9 | var modulesDirectories = [ | |
10 | 'node_modules', | |
11 | 'bower_components/purescript-prelude/src', | |
12 | output | |
13 | ]; | |
14 | ||
464355c7 | 15 | var config |
16 | = { entry: './src/entry' | |
17 | , output: { path: __dirname | |
1983893b | 18 | , pathinfo: true |
464355c7 | 19 | , filename: 'bundle.js' |
20 | } | |
1983893b | 21 | , module: { loaders: [ { test: /\.purs$/ |
22 | , loader: 'purs-loader?output=' + output + '&' + srcs.concat(ffis).join('&') | |
23 | } ] } | |
24 | , resolve: { modulesDirectories: modulesDirectories | |
464355c7 | 25 | , extensions: ['', '.js', '.purs'] |
26 | } | |
27 | , resolveLoader: { root: path.join(__dirname, 'node_modules') } | |
28 | } | |
29 | ; | |
30 | ||
31 | module.exports = config; |