当前位置: 首页 > news >正文

做网站导航栏素材图国外教做蛋糕的网站

做网站导航栏素材图,国外教做蛋糕的网站,哪些网站可以免费做推广呢,遵义论坛网Vue3【二十一】Vue 路由模式#xff08;createWebHashHistory /createWebHistory #xff09;和RouterLink写法 Vue3【二十一】Vue 路由模式和普通组件目录结构 createWebHistory history模式#xff1a;url不带#号#xff0c;需要后端做url适配 适合销售项目 利于seo crea…Vue3【二十一】Vue 路由模式createWebHashHistory /createWebHistory 和RouterLink写法 Vue3【二十一】Vue 路由模式和普通组件目录结构 createWebHistory history模式url不带#号需要后端做url适配 适合销售项目 利于seo createWebHashHistory Hash模式url 带#号不需要url适配比较适合后端项目 不利于seo 路由命名 和 配置路由规则 Header 组件是一般组件一般放到components文件夹中 News About Home 组件是路由组件一般存放在pages或views文件夹中 /*注意 1、路由逐渐通常存放在pages或views文件夹一般组件通常存放在components文件夹中 2、通过点击路由链接切换路由组件视觉上‘消失’了的路由组件默认是被 卸载 掉的需要的时候再去挂载 3、路由组件切换时会触发组件的beforeRouteEnter、beforeRouteUpdate、beforeRouteLeave钩子函数 实例截图 目录结构 代码 app.vue templatediv classappHeader/Header!-- 导航区 --div classnavigateRouterLink to/home active-classactive 首页 /RouterLink!-- RouterLink to/news active-classactive 新闻 /RouterLink --!-- to的对象写法 --!-- 名称跳转 -- RouterLink :to{name:xinwen} active-classactive 新闻 /RouterLink!-- 路径跳转 --RouterLink :to{path:/about} active-classactive 关于 /RouterLink/div!-- 展示区 --div classmain-contentRouterView //div/div /templatescript langts setup nameApp // npm install vue-router //安装路由器import { RouterView } from vue-router; import Header from /components/Header.vue; // Header 组件是一般组件一般放到components文件夹中 // News About Home 组件是路由组件一般存放在pages或views文件夹中/*注意 1、路由逐渐通常存放在pages或views文件夹一般组件通常存放在components文件夹中 2、通过点击路由链接切换路由组件视觉上‘消失’了的路由组件默认是被 卸载 掉的需要的时候再去挂载 3、路由组件切换时会触发组件的beforeRouteEnter、beforeRouteUpdate、beforeRouteLeave钩子函数*//scriptstyle scoped .app {background-color: #4fffbb;box-shadow: 0 0 10px;border-radius: 10px;padding: 10px; } .navigate {display: flex;justify-content: space-around;margin: 0 100px; } .navigate a {display: block;text-align: center;width: 90px;height: 40px;line-height: 40px;border-radius: 10px;background-color: #818080;text-decoration: none;color: #fff;/* font-size: 5px; */letter-spacing: 5px; } .navigate a.active {color: #ffc268;background-color: #fff;border: 1px solid #ffc268;font-weight: 900;/* text-shadow: 0 0 1px black; */font-family: 微软雅黑; }.main-content {margin: 0 auto;margin-top: 30px;margin-bottom: 30px;border-radius: 10px;width: 90%;height:400px;border: 1px solid; } /styleHeader.vue templateh2 classtitleVue3 路由和组件页面切换测试/h2 /templatescript setup langts nameHeader/scriptstyle scoped.title{text-align: center;word-spacing: 5px;margin: 30px 0;height: 70px;line-height: 70px;background-image: linear-gradient(45deg, #cecece, #fff);border-radius: 10px;box-shadow: 0 0 2px;font-size: 30px } /styleindex.ts // 创建一个路由器并暴漏出去// 第一步引入createRouter import { createRouter, createWebHashHistory, createWebHistory } from vue-router // 引入各种组件 import Home from /pages/Home.vue import About from /pages/About.vue import News from /pages/News.vue // 第二步创建路由器 const router createRouter({// 配置路由模式 // createWebHistory history模式url不带#号需要后端做url适配 适合销售项目 利于seo// createWebHashHistory Hash模式url 带#号不需要url适配比较适合后端项目 不利于seohistory: createWebHistory(),// 配置路由规则routes: [// { path: /, redirect: /home },// { path: /home, component: Home },// { path: /about, component: About },// { path: /news, component: News }// 路由命名{ path: /, redirect: /home },{ path: /home, name: zhuye, component: Home },{ path: /about, name: guanyu, component: About },{ path: /news, name: xinwen, component: News }] })// 第三步导出路由器 export default routerhome.vue templatediv classhomeimg src/public/logo.png alt/div /templatescript setup langts nameHome/scriptstyle scoped .home {display: flex;justify-content: center;align-items: center;height: 100%; } img {width: 10%; } /style
http://www.hkea.cn/news/14559941/

相关文章:

  • 开发网站多少钱拍卖网站模板下载
  • 唐朝网站社区网站设计策划书3000字
  • 网站被挂马怎么处理百度知道山东网站建设
  • 网站建设是广告吗在农村做相亲网站怎么样
  • 天天网站建设wordpress 迷
  • 门户网站 移动端厦门百度广告开户
  • 网站优化排名优化有了域名 网站建设
  • 免费网站空间论坛广丰网站建设
  • 在哪下载免费的英文版网站模板h5制作软件免费版
  • 甘肃网站开发公司写一篇软文多少钱
  • 在本地做装修在那个网站好图片网站源码asp
  • 统一管理网站系统网站推广是做什么的
  • 怎么查看网站备案商生产erp软件
  • 建设一个电商网站的步骤花西子网络营销策划方案
  • 付网站建设费用计入科目网站连锁店查询怎么做
  • 做品牌折扣的网站wordpress彩色标签
  • 适合小型网络公司的建站方式可以为代理网络手游
  • 如何建设一个好的网站网站建设pdf下载
  • 我的世界充值网站怎么做平面设计图制作
  • 如何免费建立网站免费做的网站怎么设置域名
  • 广安做网站的公司海拉尔网站建设公司
  • 常州 招网站开发免费php企业网站管理系统
  • 搜讯网站建设上海城隍庙小吃推荐
  • 网站建设视觉设计wordpress 修改点击数
  • 怎么做王者荣耀网站whois查询 站长工具
  • 网站免费建设推荐百度广告代理商
  • 怎么引导做淘宝的客户做官方网站鹿邑建设局官方网站
  • 东莞市品牌网站建设价格网站群建设优点
  • 网站怎么上传到空间网站建设医药
  • 温州敎玩具网站建设海外精品网站建设