2***@qq.com
2***@qq.com
  • 发布:2024-11-05 15:33
  • 更新:2024-11-05 15:34
  • 阅读:35

TypeError: Cannot read property '$templateRefs' of null

分类:uni-app

添加微信小程序,底部tabbar,切换时,偶发

vendor.js? [sm]:3614 TypeError: Cannot read property '$templateRefs' of null
at setRef (vendor.js:7126)
at Object.sr (vendor.js:7138)
at Proxy._sfc_render (list.js:141)
at renderComponentRoot (vendor.js? [sm]:6502)
at ReactiveEffect2.componentUpdateFn [as fn] (vendor.js? [sm]:6601)
at ReactiveEffect2.run (vendor.js? [sm]:2493)
at instance.update (vendor.js? [sm]:6646)
at setupRenderEffect (vendor.js? [sm]:6656)
at mountComponent (vendor.js? [sm]:6450)
at createComponent22 (vendor.js? [sm]:6707)(env: Windows,mp,1.06.2409140; lib: 3.6.4)

是什么原因?怎么排查?

2024-11-05 15:33 负责人:无 分享
已邀请:
2***@qq.com

2***@qq.com (作者)

生成后的代码为:

{  
  "pages": [  
    "uni_modules/uni-cms-article/pages/list/list",  
    "uni_modules/uni-cms-article/pages/search/search",  
    "uni_modules/uni-cms-article/pages/detail/detail",  
    "uni_modules/uni-cms-article/pages/detail/preview",  
    "uni_modules/uni-cms-article/pages/webview/webview",  
    "pages/index/index"  
  ],  
  "window": {  
    "navigationBarTextStyle": "black",  
    "navigationBarTitleText": "uni-app",  
    "navigationBarBackgroundColor": "#F8F8F8",  
    "backgroundColor": "#F8F8F8"  
  },  
  "tabBar": {  
    "color": "#7A7E83",  
    "selectedColor": "#3cc51f",  
    "borderStyle": "black",  
    "backgroundColor": "#ffffff",  
    "list": [  
      {  
        "pagePath": "pages/index/index",  
        "iconPath": "static/tabbar/list.png",  
        "selectedIconPath": "static/tabbar/list_active.png",  
        "text": "列表"  
      },  
      {  
        "pagePath": "uni_modules/uni-cms-article/pages/list/list",  
        "iconPath": "static/tabbar/grid.png",  
        "selectedIconPath": "static/tabbar/grid_active.png",  
        "text": "接口"  
      },  
      {  
        "pagePath": "uni_modules/uni-cms-article/pages/search/search",  
        "iconPath": "static/tabbar/me.png",  
        "selectedIconPath": "static/tabbar/me_active.png",  
        "text": "我的"  
      }  
    ]  
  },  
  "usingComponents": {}  
}

要回复问题请先登录注册