惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Project Zero
Project Zero
F
Fortinet All Blogs
博客园 - 叶小钗
阮一峰的网络日志
阮一峰的网络日志
月光博客
月光博客
爱范儿
爱范儿
博客园_首页
S
Security @ Cisco Blogs
H
Heimdal Security Blog
Cyberwarzone
Cyberwarzone
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
T
Tailwind CSS Blog
T
Threatpost
博客园 - 司徒正美
The GitHub Blog
The GitHub Blog
WordPress大学
WordPress大学
S
Security Affairs
AWS News Blog
AWS News Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Cisco Talos Blog
Cisco Talos Blog
博客园 - 聂微东
P
Privacy & Cybersecurity Law Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
NISL@THU
NISL@THU
G
GRAHAM CLULEY
人人都是产品经理
人人都是产品经理
L
LangChain Blog
The Register - Security
The Register - Security
L
LINUX DO - 最新话题
博客园 - 【当耐特】
P
Proofpoint News Feed
Schneier on Security
Schneier on Security
Application and Cybersecurity Blog
Application and Cybersecurity Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
P
Proofpoint News Feed
IT之家
IT之家
云风的 BLOG
云风的 BLOG
量子位
D
Darknet – Hacking Tools, Hacker News & Cyber Security
PCI Perspectives
PCI Perspectives
腾讯CDC
大猫的无限游戏
大猫的无限游戏
美团技术团队
N
News | PayPal Newsroom
Recent Commits to openclaw:main
Recent Commits to openclaw:main
D
Docker
A
Arctic Wolf
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
Cloudbric
Cloudbric

博客园 - 上官帅帅

vue 环境配置 vue html DOM树对象 idea maven pom配置文件 .net core dapper (5) .net core dapper (4) .net core dapper (3) .net core dapper (2) .net core dapper (1) c# 异步 async await jq_js window 使用vagrant搭建开发开发环境 判断元素的属性是否存在 js 查找树节点 数组去重 redis 基础知识 jQuey知识点三 解析json数据 mysql 基础操作一 ruby 基础知识三 读写文件 Active Record 数据迁移
vue3 - 01 路由的配置和使用
上官帅帅 · 2026-01-26 · via 博客园 - 上官帅帅

element-plus 官网组件

https://element-plus.org/zh-CN/component/overview

 路由的配置和使用

1 安装

npm install vue-router@next --save

1.1创建相关页面

image

2 配置路由 index.ts

import {createRouter,createWebHistory} from 'vue-router'
import LoginPage from '../views/index/LoginPage.vue'

const router=createRouter({
     history:createWebHistory(),
    routes:[
        {path:"/login",component:LoginPage}]
})

export default router;

3 main.ts 中use router

createApp(App)
.use(ElementPlus)
.use(router)
.mount('#app')

4 在app.vue 中加路由标签

<router-view></router-view>