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(model): make .changed() deep aware #10851

Merged
merged 3 commits into from Oct 19, 2019
Merged

Conversation

@SimonSchick
Copy link
Member

@SimonSchick SimonSchick commented Apr 27, 2019

Pull Request check-list

Please make sure to review and check all of these items:

  • Does npm run test or npm run test-DIALECT pass with this change (including linting)?
  • Does the description below contain a link to an existing issue (Closes #[issue]) or a description of the issue you are solving?
  • Have you added new tests to prevent regressions?
  • Is a documentation update included (if this change modifies existing APIs, or introduces new ones)?
  • Did you follow the commit message conventions explained in CONTRIBUTING.md?

Description of change

Fixes #10848

@sushantdhiman the problem here is that this change would be in conflict with current behaviour, we could deep clone complex values values when storing the previous values, this probably has some performance implications tho.

Imo we should suggest to consumers that when they edit nested properties that they have to call changed('key', true) manually.

@codecov
Copy link

@codecov codecov bot commented Apr 27, 2019

Codecov Report

Merging #10851 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #10851      +/-   ##
==========================================
+ Coverage   96.27%   96.27%   +<.01%     
==========================================
  Files          94       94              
  Lines        9186     9190       +4     
==========================================
+ Hits         8844     8848       +4     
  Misses        342      342
Impacted Files Coverage Δ
lib/model.js 96.47% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 481bddd...4396bda. Read the comment docs.

@sushantdhiman sushantdhiman merged commit 29c9be3 into master Oct 19, 2019
4 checks passed
@sushantdhiman sushantdhiman deleted the fix/change-detection-nesting branch Oct 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

4 participants