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

Fix drp cloning #293

Closed
JanLewDev opened this issue Dec 22, 2024 · 0 comments · Fixed by #296
Closed

Fix drp cloning #293

JanLewDev opened this issue Dec 22, 2024 · 0 comments · Fixed by #296

Comments

@JanLewDev
Copy link
Contributor

JanLewDev commented Dec 22, 2024

Currently canvas example does not run, when trying to paint a pixel it throws an error (screenshot below).
image

This is because when deep cloning the drp with the current approach

		this.originalDRP = Object.create(
			Object.getPrototypeOf(drp),
			Object.getOwnPropertyDescriptors(structuredClone(drp)),
		);

comparing drp and originalDRP, the cloning converts Pixel objects to just objects with the functions, both logged below
image

@JanLewDev JanLewDev changed the title Fix canvas example Fix drp cloning Dec 22, 2024
@github-project-automation github-project-automation bot moved this from Triage to 🏆 Done in Project Management Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
1 participant