收藏
回答

mp-sticky 构建npm后报错,有遇到的没?

1

npm i @miniprogram-component-plus/sticky --save

2

开发者工具构建 npm,勾选“使用 npm 模块”


3 刷新开发者工具,报错出现

VM60603:1 thirdScriptError
Behaviors should be constructed with Behavior()
Error: Behaviors should be constructed with Behavior()
    at H (http://127.0.0.1:18239/appservice/__dev__/WAService.js:2:1568153)
    at Ie (http://127.0.0.1:18239/appservice/__dev__/WAService.js:2:1570862)
    at Module.t (http://127.0.0.1:18239/appservice/__dev__/WAService.js:2:1581757)
    at _t (http://127.0.0.1:18239/appservice/__dev__/WAService.js:2:1693707)
    at Object.Vt [as originalComponent] (http://127.0.0.1:18239/appservice/__dev__/WAService.js:2:1711764)
    at Object.GrowingComponent (http://127.0.0.1:18239/appservice/utils/index.js:643:31)
    at Component (http://127.0.0.1:18239/appservice/utils/index.js:670:33)
    at c (http://127.0.0.1:18239/appservice/miniprogrampatch.js:272:119)
    at highjackedFn (http://127.0.0.1:18239/appservice/miniprogram_npm/minax/index.js:235:11)
    at Object._ (http://127.0.0.1:18239/appservice/miniprogram_npm/@miniprogram-component-plus/sticky/index.js:121:9)
回答关注问题邀请回答
收藏

2 个回答

  • Code Weaver
    Code Weaver
    2020-05-07

    先使用position:sticky吧。

    2020-05-07
    有用
    回复
  • 尼克翔
    尼克翔
    2020-05-07

    同样步骤 使用 select-text 组件没有报错。

    2020-05-07
    有用
    回复
登录 后发表内容
问题标签