Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- https://nuxtjs.org/docs/directory-structure/components/#dynamic-imports
- <LazyMountainsList v-if="show" />
- <lazy-mountains-list v-if="show" />
- vue
- <template>
- <div>
- <lazy-component />
- </div>
- </template>
- <script>
- const lazyComponent = () => import('Component.vue')
- export default {
- components: { lazyComponent }
- }
- // Another syntax
- export default {
- components: {
- lazyComponent: () => import('Component.vue')
- }
- }
- </script>
Add Comment
Please, Sign In to add comment