File tree Expand file tree Collapse file tree 4 files changed +11
-9
lines changed
Expand file tree Collapse file tree 4 files changed +11
-9
lines changed Original file line number Diff line number Diff line change 88 ],
99 "plugins" : [
1010 " dynamic-import-webpack" ,
11- " transform-class-properties"
11+ " transform-class-properties" ,
12+ " transform-object-rest-spread"
1213 ]
1314}
Original file line number Diff line number Diff line change @@ -12,10 +12,12 @@ module.exports = {
1212 'parser' : 'babel-eslint' ,
1313 'plugins' : [
1414 'standard' ,
15- 'promise'
15+ 'promise' ,
16+ 'prefer-object-spread'
1617 ] ,
1718 'rules' : {
18- 'semi' : [ 'error' , 'always' ] ,
19- 'no-var' : 'error'
19+ 'no-var' : 'error' ,
20+ 'prefer-object-spread/prefer-object-spread' : 2 ,
21+ 'semi' : [ 'error' , 'always' ]
2022 }
2123} ;
Original file line number Diff line number Diff line change 1717 "babel-loader" : " ^7.1.2" ,
1818 "babel-plugin-dynamic-import-webpack" : " ^1.0.1" ,
1919 "babel-plugin-transform-class-properties" : " ^6.24.1" ,
20+ "babel-plugin-transform-object-rest-spread" : " ^6.26.0" ,
2021 "babel-preset-env" : " ^1.6.0" ,
2122 "css-loader" : " ^0.28.6" ,
2223 "debounce" : " ^1.0.2" ,
2324 "eslint" : " ^4.5.0" ,
2425 "eslint-config-standard" : " ^10.2.1" ,
2526 "eslint-plugin-import" : " ^2.7.0" ,
2627 "eslint-plugin-node" : " ^5.1.1" ,
28+ "eslint-plugin-prefer-object-spread" : " ^1.2.1" ,
2729 "eslint-plugin-promise" : " ^3.5.0" ,
2830 "eslint-plugin-standard" : " ^3.0.1" ,
2931 "extract-text-webpack-plugin" : " ^3.0.0" ,
3739 "html-webpack-plugin" : " ^2.30.1" ,
3840 "htmllint-loader" : " ^1.3.8" ,
3941 "node-sass" : " ^4.5.3" ,
40- "object-assign" : " ^4.1.1" ,
4142 "postcss-loader" : " ^2.0.6" ,
4243 "sass-loader" : " ^6.0.6" ,
4344 "style-loader" : " ^0.18.2" ,
Original file line number Diff line number Diff line change 1- import objectAssign from 'object-assign' ; // Object.assign is missing in e.g. IE11
2-
31// TODO: just use ES6 class...
42const AnimatedPolyline = function ( options ) {
53 options = options || { } ;
@@ -8,9 +6,9 @@ const AnimatedPolyline = function (options) {
86 strokeStyle : '#f1dbce' ,
97 lineWidth : 4 ,
108 animated : true ,
11- animateAmount : 4
9+ animateAmount : 4 ,
10+ ...options
1211 } ;
13- objectAssign ( this . options , options ) ;
1412
1513 this . finished = false ;
1614 this . segments = options . segments ;
You can’t perform that action at this time.
0 commit comments