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

[BUGFIX lts] dont access properties during init unless required #19023

Merged
merged 1 commit into from
Jun 20, 2020

Conversation

runspired
Copy link
Contributor

Previously we were greedily accessing properties during init in all cases if a value for the property was passed into create. In the case of native getters/setters this could lead to rendering invalidations if initialization was triggered during render since the value would immediately change after access.

This possibly supplants #19009 and may fix if so #19003 but more investigation should be done to confirm that.

@runspired
Copy link
Contributor Author

After further investigation this issue began in the 3.15 release and was not present prior, so backporting to 3.16 will allow EmberData to use this pattern back to 3.12 :)

@rwjblue rwjblue merged commit 432a10f into emberjs:master Jun 20, 2020
@rwjblue
Copy link
Member

rwjblue commented Jun 20, 2020

Thanks for tracking this down!

@rwjblue
Copy link
Member

rwjblue commented Jun 22, 2020

@runspired / @snewcomer - This is included in ember-source@3.20.0-beta.3, mind testing to confirm that this fixes that issue in Ember Data?

@runspired
Copy link
Contributor Author

@rwjblue I tested this locally before submitting, but I'll run a quick test to double ensure :)

@rwjblue
Copy link
Member

rwjblue commented Jun 22, 2020

Ah, gotcha, thank you! I mostly just want a little bit of sanity check before releasing the patch release of 3.19 (and then more sanity check of that patch release before backporting to 3.16).

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.

3 participants