Skip to content

umi 的 entry 不允许改的情况下,怎么在加载启动 umi 之前替换 require 实现? #6652

Discussion options

You must be logged in to vote

解决了,通过自己创建一个 umi plugin,再配一下 config.ts 里的plugins 引入,使用 api.addEntryCodeAhead 引入需要的代码在最前面

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@xiaohuoni
Comment options

Answer selected by biaomingzhong
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants