Skip to content

Commit 12396e1

Browse files
authored
Merge pull request #112 from surmon-china/master
v1.15.0 支持 polyfill
2 parents 1b61313 + b8badc4 commit 12396e1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+1058
-447
lines changed

.circleci/config.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@ workflows:
22
version: 2
33
build:
44
jobs:
5-
- build_node_6
65
- build_node_8
6+
- build_node_10
77

88
version: 2
99
jobs:
1010
base: &base
1111
working_directory: ~/workspace
1212
docker:
13-
- image: circleci/node:6.11
13+
- image: circleci/node:8.16.1
1414
steps:
1515
- checkout
1616
- restore_cache:
@@ -27,12 +27,12 @@ jobs:
2727
paths:
2828
- "node_modules"
2929

30-
build_node_6:
30+
build_node_8:
3131
<<: *base
3232
docker:
33-
- image: circleci/node:6.11
33+
- image: circleci/node:8.16.1
3434

35-
build_node_8:
35+
build_node_10:
3636
<<: *base
3737
docker:
38-
- image: circleci/node:8.9
38+
- image: circleci/node:10.16.3

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,10 @@ npm 包与 docker 镜像的对比,优点:
178178

179179
优化项
180180

181+
- addPolyfill
182+
183+
是否开启自动 polyfill 功能,开启后会根据 `targets` 参数自动打包对应的 polyfill,并在作为独立的包被页面前置引用,`true` 启用,`false` 禁用
184+
181185
- extractCommon
182186

183187
控制是否抽取 entries 间的公共内容到单独的文件中,在有多个 entry 时可以减少结果文件的总体积,`true` 启用,`false` 禁用

lib/clean.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file clean dist
33
* @author nighca <nighca@live.cn>
44
*/

lib/constants/chunks.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
/*
1+
/**
22
* @file chunks
33
* @author nighca <nighca@live.cn>
44
*/
55

66
module.exports = {
77
common: 'fec__common',
8-
manifest: 'fec__manifest'
8+
manifest: 'fec__manifest',
9+
polyfill: 'fec__polyfill'
910
}

lib/constants/files.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file file names
33
* @author nighca <nighca@live.cn>
44
*/

lib/constants/transforms.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file all valid transforms
33
* @author nighca <nighca@live.cn>
44
*/

lib/generate.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file generate dist files
33
* @author nighca <nighca@live.cn>
44
*/

lib/prepare.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file prepare behaviors
33
* @author nighca <nighca@live.cn>
44
*/

lib/test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file run unit test
33
* @author nighca <nighca@live.cn>
44
*/

lib/upload.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/**
22
* @file upload files
33
* @author nighca <nighca@live.cn>
44
*/

0 commit comments

Comments
 (0)