Skip to content

Commit 7305e3f

Browse files
author
Daniel de la Cruz
committed
v0.2.0
1 parent 34d8bf7 commit 7305e3f

File tree

4 files changed

+11
-4
lines changed

4 files changed

+11
-4
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ build/Release
3030
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
3131
node_modules
3232

33+
# Vendors file
34+
vendors.js
35+
3336

3437
### OSX ###
3538
.DS_Store
@@ -58,7 +61,6 @@ Network Trash Folder
5861
Temporary Items
5962
.apdisk
6063

61-
6264
### Sass ###
6365
.sass-cache
6466
*.css.map

.npmignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,4 @@ scripts
1111
.scss-lint.yml
1212
npm-debug.log
1313
webpack.config.js
14+
vendors.js

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-feature-toggle",
3-
"version": "0.1.0",
3+
"version": "0.2.0",
44
"main": "dist/",
55
"scripts": {
66
"clean:lib": "rimraf ./lib/*",

webpack.config.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,10 @@ if(TARGET === 'start:server' || !TARGET) {
6262

6363
if(TARGET === 'dist') {
6464
module.exports = merge(base, {
65-
entry: path.resolve(__dirname, 'docs/index.jsx'),
65+
entry: {
66+
app: path.resolve(__dirname, 'docs/index.jsx'),
67+
vendors: ['react', 'react-dom', 'babel-polyfill']
68+
},
6669
output: {
6770
filename: 'dist/index.js'
6871
},
@@ -71,7 +74,8 @@ if(TARGET === 'dist') {
7174
compress: {
7275
warnings: false
7376
}
74-
})
77+
}),
78+
new webpack.optimize.CommonsChunkPlugin('vendors', 'vendors.js')
7579
]
7680
});
7781
}

0 commit comments

Comments
 (0)