DEV Community

Discussion on: Thought on Vue 3 Composition API - `reactive()` considered harmful

Collapse
 
andykras profile image
Andrey Krasnov

this should work the same way as ref()

const blog = reactive({posts: []})
blog.posts = await fetchBlogPosts()
Collapse
 
ycmjason profile image
YCM Jason

Exactly! So just use ref!