Questions tagged [async-components]
26 questions
9
votes
5 answers
How can i use Vue Async components?
I'm using laravel 5.4 and vue 2 and I want to load a component as async using a button. My Vue js components are separate: example.vue and test.vue and I load them as an html tag.
This is my app.js:
import './bootstrap';
import example from…

K1-Aria
- 1,093
- 4
- 21
- 34
6
votes
0 answers
How to build individual component chunks with Vite to load with defineAsyncComponent
I'm not sure this is even possible, but it looks like some of the moving parts are there.
GOAL:
Create a library of single file Vue 3 components that will compile into separate chunks using Vite, and be dynamically/async loaded at runtime. The app…

jtalarico
- 886
- 8
- 22
4
votes
2 answers
Vue3 top-level await Eslint fails
Following the official documentation: https://vuejs.org/api/sfc-script-setup.html#top-level-await
I'm trying to create an async component like that:
Async data: {{asyncData}}