Vue.js · Composition API · Junior · Debugging
Sharing state with a module-level ref composable?
Short Interview Answer
A singleton ref outside the function creates shared state across callers.
Detailed Explanation
Intentional for global stores; accidental for per-component state—create refs inside the function.