We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[vue] 如果让你从零开始写一个vue路由,说说你的思路
The text was updated successfully, but these errors were encountered:
创建完页面后,在router.js里创建一个路径,(一般刚创建项目时会有Home和About的示例,我都是直接复制一下他们的路由然后再改成自己的),然后在对应的页面中引用
Sorry, something went wrong.
就是暴露install 和 router 然后初始化 还有注册link view 组件 监听hash变化 切换当前组件 然后render实现不同组件的渲染 这只是hash模式
import Router from 'vue-router'; Vue.user(Router);
export default new Router({ mode: '', path: '', name: '', ... });
No branches or pull requests
[vue] 如果让你从零开始写一个vue路由,说说你的思路
The text was updated successfully, but these errors were encountered: