邃芒官网(PC) https://www.metavatar.cc
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
 
 
 

62 rader
1.3 KiB

  1. /*
  2. * @Autor: Chuting
  3. * @Date: 2022-08-08 14:23:52
  4. * @LastEditors: Chuting
  5. * @LastEditTime: 2022-08-10 23:19:14
  6. * @Description:
  7. */
  8. import Vue from 'vue'
  9. import VueRouter from 'vue-router'
  10. Vue.use(VueRouter)
  11. // 解决ElementUI导航栏中的vue-router在3.0版本以上重复点菜单报错问题
  12. const originalPush = VueRouter.prototype.push
  13. VueRouter.prototype.push = function push(location) {
  14. return originalPush.call(this, location).catch(err => err)
  15. }
  16. const routes = [
  17. {
  18. path: '/',
  19. name: 'Home',
  20. // component: Home
  21. component: ()=> import("../components/home/home"),
  22. },
  23. {
  24. path: '/aboutUe',
  25. name: 'aboutUe',
  26. // component: Home
  27. component: ()=> import("../components/aboutUe/aboutUe"),
  28. },
  29. {
  30. path: '/styleAdd/:id?',
  31. name: 'styleAdd',
  32. // component: Home
  33. component: ()=> import("../components/styleAdd/styleAdd"),
  34. },
  35. {
  36. path: '/case',
  37. name: 'case',
  38. component: ()=> import("@/components/case"),
  39. },
  40. {
  41. path: '/technology',
  42. name: 'technology',
  43. component: ()=> import("@/components/technology"),
  44. },
  45. {
  46. path: '/introduce/:id?',
  47. name: 'introduce',
  48. component: ()=> import("@/components/introduce"),
  49. }
  50. ]
  51. const router = new VueRouter({
  52. mode: 'history',
  53. base: process.env.BASE_URL,
  54. routes
  55. })
  56. export default router