-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: livedemo disabled when config babel-plugin-import #2195
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
||
- 不需要 live demo:忽略警告即可 | ||
- 希望开启 live demo: | ||
- style: false 直接去掉插件即可 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
我评论的只是个提纲…语句还是要完善下的,比如 style: false
这个估计没人看得懂,且默认就是 false
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hahaha好的, 下次.
); | ||
if (disableFlag) { | ||
logger.warn( | ||
'live demo feature has been automatically disabled since babel-plugin-import be registered, if you want to enable live demo feature, checkout: https://d.umijs.org/guide/faq', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
链接加一下锚点
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
嗯, 想的是有中文且encode
后太长了.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
应该可以给文本加超链接,其他项目里看到过
🤔 这个变动的性质是?/ What is the nature of this change?
🔗 相关 Issue / Related Issue
#2193
💡 需求背景和解决方案 / Background or solution
用户配置按需加载后,
babel-plugin-import
会擦除dumi
注入livedemo context
的相关import * as
语句, 导致context
内的变量未定义why 禁用 ?
浏览器用户源码编译是不经过
babel-plugin
处理的, 目前也没有必要改变这一现状.禁用一不会报错, 二不会影响存量用户.
📝 更新日志 / Changelog