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

Move TresObject.__tres to a WeakMap #591

Open
4 tasks done
andretchen0 opened this issue Mar 18, 2024 · 0 comments · May be fixed by #593
Open
4 tasks done

Move TresObject.__tres to a WeakMap #591

andretchen0 opened this issue Mar 18, 2024 · 0 comments · May be fixed by #593
Labels
p1-chore Doesn't change end-user code behavior (priority)

Comments

@andretchen0
Copy link
Contributor

andretchen0 commented Mar 18, 2024

Problem

src/core/nodeOps.ts currently saves data associated with a given THREE object in the object's userData. This means it can be modified or deleted by users.

Solution

Move the data to a WeakMap that's private to nodeOps.

Additional context

Dicussed here.

Validations

@alvarosabu alvarosabu linked a pull request Mar 20, 2024 that will close this issue
@alvarosabu alvarosabu added p1-chore Doesn't change end-user code behavior (priority) and removed enhancement v4 labels Mar 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p1-chore Doesn't change end-user code behavior (priority)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants