Skip to content

Commit 25344ac

Browse files
committed
Add Lazy Loading Routes 🍕
1 parent 327e323 commit 25344ac

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/router/index.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import Vue from 'vue'
22
import Router from 'vue-router'
3-
import Home from '@/components/Home'
4-
import Profile from '@/components/User/Profile'
5-
import Signup from '@/components/User/Signup'
6-
import Signin from '@/components/User/Signin'
3+
const Home = () => import('@/components/Home')
4+
const Profile = () => import('@/components/User/Profile')
5+
const Signup = () => import('@/components/User/Signup')
6+
const Signin = () => import('@/components/User/Signin')
77
import AuthGuard from './auth-guard'
88

99
Vue.use(Router)

0 commit comments

Comments
 (0)