File tree Expand file tree Collapse file tree 2 files changed +23
-4
lines changed Expand file tree Collapse file tree 2 files changed +23
-4
lines changed Original file line number Diff line number Diff line change 11
11
"build:img" : " cpr images/ dist/images/ --overwrite" ,
12
12
"test" : " npm run lint" ,
13
13
"lint" : " npm run lint:js && npm run lint:css" ,
14
- "lint:js" : " eslint 'src/**'" ,
14
+ "lint:js" : " eslint 'src/**' '*.js' " ,
15
15
"lint:css" : " prettier --list-different '*.css'" ,
16
16
"publish" : " sh ./scripts/publish.sh" ,
17
17
"postpublish" : " sh ./scripts/postpublish.sh"
45
45
"eslint" : " ^4.15.0" ,
46
46
"eslint-plugin-prettier" : " ^2.4.0" ,
47
47
"prettier" : " ^1.9.2" ,
48
- "rollup" : " ^0.53.2"
48
+ "rollup" : " ^0.65.0" ,
49
+ "rollup-plugin-uglify" : " ^5.0.2" ,
50
+ "uglify-js" : " ^3.4.9"
49
51
}
50
52
}
Original file line number Diff line number Diff line change 1
1
import pkg from './package.json' ;
2
+ import { uglify } from 'rollup-plugin-uglify' ;
2
3
3
4
var banner =
4
5
'/* @preserve\n' +
@@ -12,7 +13,7 @@ var banner =
12
13
' * All rights reserved.\n' +
13
14
' */\n' ;
14
15
15
- export default {
16
+ const config = Object . freeze ( {
16
17
input : 'src/index.js' ,
17
18
external : [ 'leaflet' ] ,
18
19
output : {
@@ -25,4 +26,20 @@ export default {
25
26
} ,
26
27
banner : banner
27
28
}
28
- } ;
29
+ } ) ;
30
+
31
+ export default [
32
+ config ,
33
+ Object . assign ( { } , config , {
34
+ plugins : [
35
+ uglify ( {
36
+ output : {
37
+ comments : 'some'
38
+ }
39
+ } )
40
+ ] ,
41
+ output : Object . assign ( { } , config . output , {
42
+ file : 'dist/Control.Geocoder.min.js'
43
+ } )
44
+ } )
45
+ ] ;
You can’t perform that action at this time.
0 commit comments