Skip to content

Support bundle with webpack #49

@sorrycc

Description

@sorrycc

Problem

目前只有 Mako 的打包方式,但有时可能出于稳定性、产物尺寸、code splitting 策略、对比等因素的考虑,会需要更老牌的 webpack 的构建方式。

Solution

提供 webpack 的构建方式,坑已经挖好,在 src/bundler/bundler_webpack.ts 里写。

逻辑是这样。

1、参考 bundler_mako.ts,基于 @umijs/bundler-webpack 实现
2、tnf 不内置 @umijs/bundler-webpack 依赖,用到了再提示用户安装
3、bundler_webpack.ts 里两个方法,应该只要实现 build 就够
4、examples/normal 里配置 bundler: 'webpack' 验证

Alternatives

No response

Importance

nice to have

Additional Information

No response

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions