Vue · Junior · Question 14 of 75
What does reactive() return?
const state = reactive({ count: 0, user: { name: "Ann" } });
state.count++;- ✓Correct answer: A deeply reactive Proxy of the object; properties are accessed without
.value - 2A copy of the object that can't be changed
- 3A ref that must be accessed with
.value
Explanation
reactive only works with objects, arrays and collections - not primitives. The Vue docs recommend ref as the primary API because it works with any value type.