FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
iClient-JavaScript/build/webpack.config.leaflet.js at master · SuperMap/iClient-JavaScript · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
SuperMap
/
iClient-JavaScript
Public
Notifications
You must be signed in to change notification settings
Fork
288
Star
906
Code
Issues
5
Pull requests
14
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
iClient-JavaScript
/
build
/
webpack.config.leaflet.js
Copy path
More file actions
More file actions
Latest commit
History
History
History
62 lines (59 loc) · 2.03 KB
Breadcrumbs
iClient-JavaScript
/
build
/
webpack.config.leaflet.js
Copy path
File metadata and controls
62 lines (59 loc) · 2.03 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
let
configBase
=
require
(
"./webpack.config.base"
)
;
//端名
const
libName
=
"leaflet"
;
//产品包名
const
productName
=
"iclient-leaflet"
;
module
.
exports
=
{
target
:
configBase
.
target
,
mode
:
configBase
.
mode
,
//页面入口文件配置
entry
:
[
...
configBase
.
entry
,
`
${
__dirname
}
/../src/leaflet/namespace.js`
,
`
${
__dirname
}
/../src/leaflet/css/index.js`
]
,
//入口文件输出配置
output
:
configBase
.
output
(
libName
,
productName
)
,
//是否启用压缩
optimization
:
configBase
.
optimization
,
//不显示打包文件大小相关警告
performance
:
configBase
.
performance
,
//其它解决方案配置
resolve
:
configBase
.
resolve
,
externals
:
Object
.
assign
(
{
}
,
configBase
.
externals
,
{
'leaflet'
:
'L'
,
'@turf/turf'
:
"function(){try{return turf}catch(e){return {}}}()"
,
'deck.gl'
:
'(function(){try{return DeckGL}catch(e){return {}}})()'
,
'luma.gl'
:
'(function(){try{return luma}catch(e){return {}}})()'
,
'webgl-debug'
:
'(function(){try{return webgl-debug}catch(e){return {}}})()'
,
'xlsx'
:
"function(){try{return XLSX}catch(e){return {}}}()"
,
three
:
'function(){try{return THREE}catch(e){return {}}}()'
}
)
,
module
:
{
rules
:
(
function
(
)
{
let
moduleRules
=
[
]
;
moduleRules
.
push
(
configBase
.
module
.
rules
.
img
)
;
const
babelConfig
=
{
test
:
[
/
\.
j
s
$
/
]
,
exclude
:
/
s
e
t
I
m
m
e
d
i
a
t
e
|
w
e
b
g
l
-
d
e
b
u
g
/
,
loader
:
'babel-loader'
,
options
:
{
presets
:
[
'@babel/preset-env'
]
,
plugins
:
[
[
'@babel/plugin-transform-runtime'
,
{
absoluteRuntime
:
false
,
corejs
:
false
,
helpers
:
false
,
regenerator
:
true
,
useESModules
:
false
}
]
]
}
}
configBase
.
moduleVersion
===
"es6"
&&
(
babelConfig
.
include
=
/
F
G
B
L
a
y
e
r
|
f
l
a
t
g
e
o
b
u
f
/
)
;
moduleRules
.
push
(
babelConfig
)
;
moduleRules
.
push
(
configBase
.
module
.
rules
.
css
)
;
return
moduleRules
}
)
(
)
}
,
plugins
:
configBase
.
plugins
(
libName
,
productName
)
}
;
Back
|
FazBrowse Home
|
New Git URL