Answer the question
In order to leave comments, you need to log in
Is it possible to include lazyloading in a Laravel project?
If you use vue-cli as a separate application, then the following construction is available out of the box:
component: () => import('./app/layouts/MainLayoutComponent'),
npm run watch
why do you give an error:Add @babel/plugin-syntax-dynamic-import (https://git.io/vb4Sv) to the 'plugins' section of your Babel config to enable parsing.
Babel config...
only webpack.mix.js
in the root of the project
. added a file to the root of the project and wrote in it:npm install @babel/plugin-syntax-dynamic-import
.babelrc
{
"plugins": ["@babel/plugin-syntax-dynamic-import"]
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question