Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace proxy wrapper #1208

Draft
wants to merge 1 commit into
base: V4_Final
Choose a base branch
from
Draft

Conversation

IzaacAyelin
Copy link
Collaborator

@IzaacAyelin IzaacAyelin commented Apr 14, 2024

Replaced Proxy with Object.defineProperty to watch only selected properties
Why?

  • Proxy handles all properties getters on the window which force us to manage ourself the values returned from the window and account for many type of values like components (eg: video player) and native functions that need to be binded correctly.
  • Proxy causes issue when functions are set to be read-only and non-configurable since we need to bind the functions which returns a new function (once a property is set to be read-only and non-configurable the Proxy must return the exact value)

@IzaacAyelin IzaacAyelin requested a review from liatv April 14, 2024 13:09
@IzaacAyelin IzaacAyelin marked this pull request as draft April 21, 2024 10:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant