composition-api icon indicating copy to clipboard operation
composition-api copied to clipboard

`toRaw()` doesn't expose Refs like in Vue 3

Open posva opened this issue 4 years ago • 17 comments

It seems like toRaw() on a reactive object doesn't expose the original properties like it does in Vue 3:

posva avatar Nov 03 '21 10:11 posva

I'm unsure of what the correct fix is here since Vue 2 modifies the object in place with methods like Vue.observable() (used in reactive and ref) differently from Vue 3, which creates a Proxy (reactive(obj) != obj). We could save a raw copy of the object passed to reactive() but it would require a deep copy and could have a small perf implication.

posva avatar Nov 16 '21 14:11 posva

Stale issue message

github-actions[bot] avatar Jan 15 '22 23:01 github-actions[bot]

Stale issue message

github-actions[bot] avatar Mar 17 '22 23:03 github-actions[bot]

Stale issue message

github-actions[bot] avatar May 17 '22 23:05 github-actions[bot]

Stale issue message

github-actions[bot] avatar Jul 17 '22 23:07 github-actions[bot]

So, how to do with it?

Benleie avatar Jul 20 '22 07:07 Benleie

Stale issue message

github-actions[bot] avatar Sep 18 '22 23:09 github-actions[bot]

Stale issue message

github-actions[bot] avatar Nov 18 '22 23:11 github-actions[bot]

Is there a solution now?

imguolao avatar Jan 14 '23 02:01 imguolao

Stale issue message

github-actions[bot] avatar Mar 15 '23 23:03 github-actions[bot]

Stale issue message

github-actions[bot] avatar Jun 02 '23 23:06 github-actions[bot]

Stale issue message

github-actions[bot] avatar Aug 02 '23 23:08 github-actions[bot]

Stale issue message

github-actions[bot] avatar Oct 02 '23 23:10 github-actions[bot]

Stale issue message

github-actions[bot] avatar Dec 02 '23 23:12 github-actions[bot]

Stale issue message

github-actions[bot] avatar Feb 01 '24 23:02 github-actions[bot]

Stale issue message

github-actions[bot] avatar Apr 02 '24 23:04 github-actions[bot]