index.js 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. import { createRouter, createWebHistory } from 'vue-router'
  2. import HomeView from '../views/HomeView.vue'
  3. const router = createRouter({
  4. history: createWebHistory(import.meta.env.BASE_URL),
  5. routes: [
  6. // {
  7. // path: '/',
  8. // name: 'home',
  9. // component: HomeView
  10. // },
  11. {
  12. path: '/',
  13. name: 'CesiumMap',
  14. component: () => import('../views/cesium.vue')
  15. },
  16. {
  17. path: '/mapview',
  18. name: 'mapview',
  19. component: () => import('../views/mapview.vue')
  20. },
  21. {
  22. path: '/satellitecloudchart',
  23. name: 'satellitecloudchart',
  24. component: () => import('../views/satellitecloudchart.vue')
  25. },
  26. //云图
  27. {
  28. path: '/cloudLayer',
  29. name: 'cloudLayer',
  30. component: () => import('../views/cesiumComponents/cloudLayer.vue')
  31. },
  32. //降雨图
  33. {
  34. path: '/rainLayer',
  35. name: 'rainLayer',
  36. component: () => import('../views/cesiumComponents/rainLayer.vue')
  37. },
  38. {
  39. path: '/about',
  40. name: 'about',
  41. // route level code-splitting
  42. // this generates a separate chunk (About.[hash].js) for this route
  43. // which is lazy-loaded when the route is visited.
  44. component: () => import('../views/AboutView.vue')
  45. },
  46. {
  47. path: "/:catchAll(.*)",
  48. redirect: "/"
  49. }
  50. ]
  51. })
  52. export default router