小贝在这里 2020-07-13 13:54 采纳率: 50%
浏览 1157

在引入taro-ui的时候 报Uncaught (in promise) TypeError: Super expression must either be null or a function 错误

小菜鸡第一次摸taro
已经cnpm install taro-ui后
在app.jsx 下 引入 import 'taro-ui/dist/style/index.scss'
在menu.jsx 下引入 import { AtTabBar } from 'taro-ui'
报错

inherits.js?258f:4 Uncaught (in promise) TypeError: Super expression must either be null or a function
    at _inherits (inherits.js?258f:4)
    at eval (component.js?a43f:15)
    at eval (component.js?a43f:15)
    at Module../node_modules/_taro-ui@2.3.4@taro-ui/dist/h5/common/component.js (0.js:687)
    at __webpack_require__ (app.js:64)
    at eval (index.js:16)
    at Module../node_modules/_taro-ui@2.3.4@taro-ui/dist/h5/components/action-sheet/index.js (0.js:771)
    at __webpack_require__ (app.js:64)
    at eval (index.js?82d2:1)
    at Module../node_modules/_taro-ui@2.3.4@taro-ui/dist/h5/index.js (0.js:1490)

请问该怎么解决

  • 写回答

1条回答 默认 最新

  • carolybbc 2020-07-15 13:46
    关注

    默认安装的taro-ui的版本,不兼容taro3
    npm install taro-ui@3.0.0-alpha.3

    评论

报告相同问题?

悬赏问题

  • ¥100 Jenkins自动化部署—悬赏100元
  • ¥15 关于#python#的问题:求帮写python代码
  • ¥20 MATLAB画图图形出现上下震荡的线条
  • ¥15 关于#windows#的问题:怎么用WIN 11系统的电脑 克隆WIN NT3.51-4.0系统的硬盘
  • ¥15 perl MISA分析p3_in脚本出错
  • ¥15 k8s部署jupyterlab,jupyterlab保存不了文件
  • ¥15 ubuntu虚拟机打包apk错误
  • ¥199 rust编程架构设计的方案 有偿
  • ¥15 回答4f系统的像差计算
  • ¥15 java如何提取出pdf里的文字?