UNPKG

664 BJavaScriptView Raw
1var path = require('path');
2var webpack = require('webpack')
3
4module.exports = {
5 entry: {
6 index: [
7 './index.js'
8 ]
9 },
10 output: {
11 path: path.join(__dirname, 'build'),
12 publicPath: '/',
13 filename: '[name].js',
14 library: 'ReactSparklines',
15 libraryTarget: 'umd'
16 },
17 externals: {
18 react: {
19 root: 'React',
20 commonjs2: 'react',
21 commonjs: 'react',
22 amd: 'react'
23 }
24 },
25 module: {
26 loaders: [{
27 test: /\.jsx?$/,
28 exclude: /(node_modules)/,
29 loader: 'babel-loader'
30 }]
31 },
32};