gpt4 book ai didi

android - 无法将 acorn-dynamic-import 节点模块安装到 Ionic Android 项目

转载 作者:行者123 更新时间:2023-11-29 16:34:29 25 4
gpt4 key购买 nike

任何人都可以解决此问题。安装 acorn 和 acorn 动态导入后,我遇到了这个错误。这与使用 ionic 和 cordova 的 Android 构建有关。

ionic cordova build android
TypeError: Cannot set property 'dynamicImport' of undefined
at injectDynamicImport (C:\git\<PROJECT_NAME>\node_modules\webpack\node_modules\acorn-dynamic-import\lib\inject.js:27:31)
at Object.<anonymous> (C:\git\<PROJECT_NAME>\node_modules\webpack\node_modules\acorn-dynamic-import\lib\index.js:17:46)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (C:\git\<PROJECT_NAME>\node_modules\webpack\lib\Parser.js:9:15)

最佳答案

我遇到过类似的问题。我使用 Arch Linux,对于可以排除一些不必要的依赖项的情况,可以在此处找到解决方案:

https://bugs.archlinux.org/task/60826

似乎是某些依赖项(可能已弃用)导致了该问题。

最好看看建议的补丁。

我已成功应用补丁。

关于android - 无法将 acorn-dynamic-import 节点模块安装到 Ionic Android 项目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52858955/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com