DEV Community

Discussion on: Use @nuxt/components to automatically import components!

Collapse
 
slaknoah profile image
Slaknoah

No, it does not, Nuxt JS page code-splitting does the magic.

From Debbie O’Brien's explanation:
"This module parses your template and automatically includes the component in the file where you are using it such as a page, layout or even a component. Because Nuxt.js uses automatic code splitting to split your pages by default this module works perfect as it will only contain the components that are used on that page. Also, if you use a component in more than 2 pages, Nuxt.js will automatically create a shared chunk for them thanks to the magic of WebPack."

You can also read more here
nuxtjs.org/blog/improve-your-devel...