Skip to content

Commit

Permalink
Use didReceiveAttrs in {{link-to}}
Browse files Browse the repository at this point in the history
This code only need to run when the arguments/attrs change, not before
every re-render. At least on the Glimmer side, the latter run more often
than the first, so this is unnecessarily doing a bunch of extra work,
invalidating expensive CPs, etc.
  • Loading branch information
chancancode authored and webark committed Oct 6, 2016
1 parent 1506d79 commit f61dd38
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/ember-htmlbars/lib/components/link-to.js
Original file line number Diff line number Diff line change
Expand Up @@ -767,7 +767,7 @@ const LinkComponent = EmberComponent.extend({
*/
loadingHref: '#',

willRender() {
didReceiveAttrs() {
let queryParams;

let params = get(this, 'params');
Expand Down

0 comments on commit f61dd38

Please sign in to comment.