When to use this skill
Use this skill whenever the user wants to:
- Install and configure Vue Router v3
- Implement routing patterns for Vue 2 applications
- Use navigation guards, history mode, or lazy-loading routes
- Reference Vue Router v3 API details
How to use this skill
- Identify the topic from the user request.
- Open the matching guide example file in
examples/. - For API details, open the matching file in
api/. - Follow official guidance and keep outputs consistent with v3 docs.
Installation mapping
examples/installation.md→ https://v3.router.vuejs.org/installation.html
Guide mapping (one-to-one with https://v3.router.vuejs.org/guide/)
Essentials
examples/guide/index.md→ https://v3.router.vuejs.org/guide/examples/guide/essentials/dynamic-matching.md→ https://v3.router.vuejs.org/guide/essentials/dynamic-matching.htmlexamples/guide/essentials/nested-routes.md→ https://v3.router.vuejs.org/guide/essentials/nested-routes.htmlexamples/guide/essentials/navigation.md→ https://v3.router.vuejs.org/guide/essentials/navigation.htmlexamples/guide/essentials/named-routes.md→ https://v3.router.vuejs.org/guide/essentials/named-routes.htmlexamples/guide/essentials/named-views.md→ https://v3.router.vuejs.org/guide/essentials/named-views.htmlexamples/guide/essentials/redirect-and-alias.md→ https://v3.router.vuejs.org/guide/essentials/redirect-and-alias.htmlexamples/guide/essentials/passing-props.md→ https://v3.router.vuejs.org/guide/essentials/passing-props.htmlexamples/guide/essentials/history-mode.md→ https://v3.router.vuejs.org/guide/essentials/history-mode.html
Advanced
examples/guide/advanced/navigation-guards.md→ https://v3.router.vuejs.org/guide/advanced/navigation-guards.htmlexamples/guide/advanced/meta.md→ https://v3.router.vuejs.org/guide/advanced/meta.htmlexamples/guide/advanced/transitions.md→ https://v3.router.vuejs.org/guide/advanced/transitions.htmlexamples/guide/advanced/data-fetching.md→ https://v3.router.vuejs.org/guide/advanced/data-fetching.htmlexamples/guide/advanced/scroll-behavior.md→ https://v3.router.vuejs.org/guide/advanced/scroll-behavior.htmlexamples/guide/advanced/lazy-loading.md→ https://v3.router.vuejs.org/guide/advanced/lazy-loading.htmlexamples/guide/advanced/navigation-failures.md→ https://v3.router.vuejs.org/guide/advanced/navigation-failures.html
API mapping (one-to-one with https://v3.router.vuejs.org/api/)
api/router-link.md→ https://v3.router.vuejs.org/api/#router-linkapi/router-view.md→ https://v3.router.vuejs.org/api/#router-viewapi/router-instance.md→ https://v3.router.vuejs.org/api/#router-instanceapi/router-options.md→ https://v3.router.vuejs.org/api/#router-optionsapi/route-object.md→ https://v3.router.vuejs.org/api/#the-route-objectapi/route-config.md→ https://v3.router.vuejs.org/api/#routesapi/navigation-guards.md→ https://v3.router.vuejs.org/api/#navigation-guards
Resources
- Installation: https://v3.router.vuejs.org/installation.html
- Guide: https://v3.router.vuejs.org/guide/
- API: https://v3.router.vuejs.org/api/
Keywords
vue-router v3, vue 2 router, routing, navigation guards, history mode, router-link, router-view, route config, route object
国内适配
- 支持中文文档和中文注释
- 示例代码兼容国内开发环境
- 提供中文 FAQ 和常见问题解答
能力边界
✅ 适用场景
- 当你需要使用此技能对应的技术栈时
- 当项目需要遵循最佳实践时
- 当需要快速上手或深入理解核心概念时
⚠️ 需要注意
- 复杂业务逻辑需要结合具体场景调整
- 性能优化需要根据实际数据量评估
❌ 不适用场景
- 不相关的技术栈或框架
- 需要完全自定义的特殊场景
使用流程
Step 1: 环境准备
确保开发环境已安装必要的依赖和工具。
Step 2: 配置初始化
根据项目需求进行基础配置。
Step 3: 核心功能使用
按照示例代码实现核心功能。
Step 4: 测试验证
运行测试确保功能正常。
Step 5: 部署上线
完成开发后进行部署和监控。