Subscribe on changes!

Nested ref returned from setup is not unwrapped in template

avatar
Dec 13th 2020

Version

3.0.4

Reproduction link

https://codesandbox.io/s/sad-maxwell-wjsqb?file=/src/App.vue

Steps to reproduce

  1. Return a plain object from in setup containing ref(s), e.g. { a: { x: computed(() => 1) } }
  2. Refer to the nested ref in template {{ a.x }}
  3. a.x will still be shown as a ref in the template

What is expected?

a.x to show the computed value

What is actually happening?

a.x is showing as a ref in template

avatar
Dec 13th 2020

oops thanks!