The syntax for asynchronous component, therefore, is as follows:
Vue.component('comp-name', (resolve, reject) => { ... })
Instead of passing an object as a second argument, we are actually passing a function with two arguments. The first is a function that you will have to call once the component (more precisely, the object that contains the properties of the component) is available. The second is another function that accepts a string. When Vue is not working in production mode, the string will be displayed in the console. You can have several reasons why the component is not working, such as an actual timeout or a connection error:
if (response.status > 400) { reject('4XX error received') } setTimeout(() => { reject('connection ...