@@ -10,7 +10,7 @@ module.exports = {
1010 target : configBase . target ,
1111 mode : configBase . mode ,
1212 //页面入口文件配置
13- entry : [ ...configBase . entry , `${ __dirname } /../src/mapboxgl/namespace.js` , `${ __dirname } /../src/mapboxgl/css/index.js` ] ,
13+ entry : [ ...configBase . entry , `${ __dirname } /../src/mapboxgl/namespace.js` , `${ __dirname } /../src/mapboxgl/css/index.js` ] ,
1414 //入口文件输出配置
1515 output : configBase . output ( libName , productName ) ,
1616 //是否启用压缩
@@ -35,7 +35,7 @@ module.exports = {
3535 module : {
3636 noParse : / [ \/ \\ ] n o d e _ m o d u l e s [ \/ \\ ] m a p b o x - g l [ \/ \\ ] d i s t [ \/ \\ ] m a p b o x - g l \. j s $ / ,
3737
38- rules : ( function ( ) {
38+ rules : ( function ( ) {
3939 let moduleRules = [ ] ;
4040 moduleRules . push ( configBase . module . rules . img ) ;
4141 const babelConfig = {
@@ -46,16 +46,16 @@ module.exports = {
4646 presets : [ '@babel/preset-env' ] ,
4747 plugins : [
4848 [
49- '@babel/plugin-transform-runtime' ,
50- {
51- absoluteRuntime : false ,
52- corejs : false ,
53- helpers : false ,
54- regenerator : true ,
55- useESModules : false
56- }
49+ '@babel/plugin-transform-runtime' ,
50+ {
51+ absoluteRuntime : false ,
52+ corejs : false ,
53+ helpers : false ,
54+ regenerator : true ,
55+ useESModules : false
56+ }
5757 ]
58- ]
58+ ]
5959 }
6060 }
6161 configBase . moduleVersion === "es6" && ( babelConfig . include = / F G B L a y e r | f l a t g e o b u f / ) ;
@@ -66,8 +66,10 @@ module.exports = {
6666 } ,
6767 plugins : [
6868 ...configBase . plugins ( libName , productName ) ,
69- new CopyPlugin ( [
70- { from : `${ __dirname } /../dist/resources/symbols` , to : `${ __dirname } /../dist/mapboxgl/resources/symbols` }
71- ] )
69+ new CopyPlugin ( {
70+ patterns : [
71+ { from : `${ __dirname } /../dist/resources/symbols` , to : `${ __dirname } /../dist/mapboxgl/resources/symbols` }
72+ ]
73+ } )
7274 ]
7375} ;
0 commit comments