question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Component helper not updating when component name changes

See original GitHub issue

I’m upgrading my app from Ember 2.18.2 to 3.1.2 and I’m running into an issue with the component helper and yielding components.

Here is a Twiddle demonstrating the issue. When the Ember dependency is set to 2.18.2 the text changes. When you set Ember to 3.0.0 the text changes. When Ember is set to 3.1.3 the text does not update.

For anyone else running into this issue, Tom Dale provided a workaround in this Twiddle.

Rob Jackson:

Tom and I dug into it a bit and came up with the same work around (using the component helper). The issue comes down to this AST transform completely failing when there are no positional or named arguments to an invocation:

https://github.com/emberjs/ember.js/blob/v3.4.0-beta.1/packages/ember-template-compiler/lib/plugins/transform-dot-component-invocation.ts#L88

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:14 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
rwjbluecommented, Sep 23, 2020

@lifeart - That is a reasonable example test case, but it does not test what this issue is reporting. Another test would need to be added that has an invocation like {{#let (component this.someThing) as |comp|}}{{comp}}{{/let}} (no other positional or named arguments).

0reactions
chriskrychocommented, Sep 7, 2021

Update: I spent some time poking at it but lack the relevant expertise. For the moment, we’re just working around it more.

Read more comments on GitHub >

github_iconTop Results From Across the Web

React components not updating with state change
The issue is that the DOM elements don't re-render on each setData() call. The sorting function works correctly if I comment out the...
Read more >
Lightning component not updating - Trailhead - Salesforce
I have a lightning component whose job is to launch a FLOW with recordId variable. I am using the JS controller to submit...
Read more >
Lightning Component not updating records
Lightning Component not updating records · 1. your Apex saveDcn method had RIM_Item__c object parameter but you send to list of Items ·...
Read more >
Why Your Vue Component Isn't Updating (and how to fix it)
Debugging Guide: Why Your Vue Component Isn't Updating (and how to fix it) · 1. Check that variables are reactive · 2. Make...
Read more >
Lightning Aura Components Developer Guide
app, while the component author can innovate and make changes without breaking consumers. You configure components by setting the named ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found