nx-js / observer-util

Transparent reactivity with 100% language coverage. Made with ❤️ and ES6 Proxies.
MIT License
1.2k stars 94 forks source link

rawToProxy WeakMap.set is never called #56

Open NesCafe62 opened 2 years ago

NesCafe62 commented 2 years ago

was reading through the code to see how observable is implemented with proxies. I saw this line https://github.com/nx-js/observer-util/blob/master/src/handlers.js#L28 and thought rawToProxy should work as a cache to avoid recreating proxy if some nested property is accessed multiple times. but after search by rawToProxy I could not find any set call.

I understand that it only affects perfomance but not affect the correcntess of behavior

edit: seems same is for proxyToRaw