Skip to content
This repository has been archived by the owner on Jan 4, 2019. It is now read-only.

Update main.js to lazy load components. #31

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@ Vue.config.debug = true;
Vue.config.devTools = true;

//Import all vue components
import posts from './components/posts.vue';
const posts = () => import('./components/posts.vue');
Vue.component( 'posts', posts );
import post from './components/post.vue';
const post = () => import('./components/post.vue');
Vue.component( 'post', post );
import header from './components/theme-header.vue';
const header = () => import('./components/theme-header.vue');
Vue.component( 'theme-header', header );
import footer from './components/theme-footer.vue';
const footer = () => import('./components/theme-footer.vue');
Vue.component( 'theme-footer', footer );
import page from './components/page.vue';
const page = () => import('./components/page.vue');
Vue.component( 'page', page );
import category from './components/category.vue';
const category = () => import('./components/category.vue');
Vue.component( 'category', category );
import tag from './components/tag.vue';
const tag = () => import('./components/tag.vue');
Vue.component( 'tag', tag );
//Create main vue component
const App = Vue.extend( {
Expand Down