Skip to content
This repository was archived by the owner on Jul 19, 2019. It is now read-only.

Commit 944d285

Browse files
committed
Update example for latest, build with Babel
1 parent 657fa30 commit 944d285

File tree

2 files changed

+15
-5
lines changed

2 files changed

+15
-5
lines changed

examples/vector-widget/package.json

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
{
22
"devDependencies": {
3-
"jsx-loader": "~0.12.0",
4-
"react": "^0.14.0-a",
5-
"react-dom": "^0.14.0-a",
6-
"webpack": "~1.0.0"
3+
"babel-core": "^6.7.7",
4+
"babel-loader": "^6.2.4",
5+
"babel-preset-es2015": "^6.6.0",
6+
"babel-preset-react": "^6.5.0",
7+
"react": "^15.0.2",
8+
"react-dom": "^15.0.2",
9+
"webpack": "^1.13.0"
710
},
811
"scripts": {
912
"postinstall": "npm install ../..",

examples/vector-widget/webpack.config.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,14 @@ module.exports = {
55
entry: './app.js',
66
module: {
77
loaders: [
8-
{ test: /\.js$/, loader: 'jsx-loader' }
8+
{
9+
loader: 'babel',
10+
test: /\.js$/,
11+
exclude: /node_modules/,
12+
query: {
13+
presets: ['es2015', 'react'],
14+
},
15+
}
916
]
1017
},
1118
plugins: [

0 commit comments

Comments
 (0)