Giter Club home page Giter Club logo

Comments (15)

bhuh12 avatar bhuh12 commented on May 26, 2024

父路由组件内必须包含 <router-tab>

  • 参考应用组件,在页签页面的父级路由组件内引入 <router-tab/>

  • 参考路由配置 配置路由信息

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

图片
图片
确实还是不行。仍然是undefined

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

不知道能否提供一个示例工程?

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

图片
是因为VUE CLI不是3的问题吗?

from vue-router-tab.

bhuh12 avatar bhuh12 commented on May 26, 2024

方法的调用是在生命周期的哪个阶段?可以放到github上重现问题吗?

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

把工程打了个包,放云盘上了。
链接:https://pan.baidu.com/s/1MQZoU3TQ6StRtveSZ0uZPw
提取码:mc1g
复制这段内容后打开百度网盘手机App,操作更方便哦

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

是在created时候调用的。

from vue-router-tab.

bhuh12 avatar bhuh12 commented on May 26, 2024

没问题啊,你输出一下 this,看是否是 vue 的组件实例

image

image

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

您使用的是node什么版本?能介绍一下开发环境和IDE环境吗?

from vue-router-tab.

bhuh12 avatar bhuh12 commented on May 26, 2024

跟这个应该没关系

  1. 先 console 输出 this ,看是否 Vue 组件的实例。$routerTab 是在 Vue 的原型链上扩展的,要在组件内部才能这样调用。
  2. 页面上是否能正常显示页签组件?
  3. 重现问题的代码,你要把出错的代码也打包进去啊,我是自己在 created 钩子里面输出的。你也参考我的方式输出看有没问题?

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

我把node从5升级到8了,一下啥问题都没有了,其它什么都没有调整。
您那边环境能告知一下吗?

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

谢谢您一路帮助,这个问题还是出来node版本上。
我这边的结论是尽量使用node8,使用最新的vue-loader。

from vue-router-tab.

bhuh12 avatar bhuh12 commented on May 26, 2024

不好意思啊,没帮上忙。
我的是 node -v v12.4.0vue -V 3.8.2,项目是用 Vue Cli 3 库模式打包的

image

from vue-router-tab.

firebear-ssl avatar firebear-ssl commented on May 26, 2024

您帮了很大的忙,感谢您制作这个控件。另外您的回复给我了很多思路,我VUE方便还很基础,方便的话加个vx。我的号是firebear

from vue-router-tab.

bhuh12 avatar bhuh12 commented on May 26, 2024

好啊,可以共同学习进步

from vue-router-tab.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.