javascript - react-loadable babel-plugin-import-inspector 不工作
问题描述
问题:
当我尝试启动节点服务器控制台尖叫:
/@babel/core/lib/transformation/file/file.js:173
throw new Error("This API has been removed. If you're looking for this " + "functionality in Babel 7, you should import the " + "'@babel/helper-module-imports' module and use the functions exposed " + " from that module, such as 'addNamed' or 'addDefault'.");
我发现使用函数 addImport() 的 babel-plugin-import-inspector 又被弃用并引发错误。
我不能停止使用这个插件,因为它与 react-loadable 高度相关;(
在这种情况下我该怎么办?我的 babel 版本是 7,可能我应该降级吗?
顺便说一句,babel 让我使用 @babel/helper-module-imports 并使用从该模块公开的函数,但我不明白如何使用。
谢谢!
解决方案
我降级了,现在看起来一切正常。
推荐阅读
- python-3.x - 使用请求,如何迭代字典来获取数据
- c# - 使用 EntityFramework Core 为每个客户选择支付最低的记录
- php - 如何为 libxml2 指定默认输出编码以防止属性中过度的实体转义?
- c - c中字符串的优先级队列
- c++ - 如何在 QWebEngineView 周围显示边框?
- c# - C#写/读文件,我应该使用锁吗
- java - 递归方法中的多个返回
- c# - 在c#中将字符串拆分为字符串数组
- javascript - 使用 JS 和 Rails 为全文用户搜索动态插入内容
- c# - 如何在 Xamarin 表单中与其他 UI 元素一起使用 ZXing.Net?