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.

link-to-external `targetRouteName` is undefined

See original GitHub issue

Within an engine the link-to-external component is throwing an error when attempting to get the external route. After stepping into the code it looks like the targetRouteName is undefined on the component. So this causes the _getExternalRoute to fail the external route lookup on the provided dependencies.

screen shot 2016-11-17 at 2 43 46 pm

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
rwjbluecommented, Nov 21, 2016

Agreed, submitted https://github.com/dgeb/ember-engines/pull/270 to address. Thanks for tracking it down!

Robert Jackson

– twitter: rwjblue – github: rjackson

On Nov 21, 2016, at 7:49 AM, Nuzsk notifications@github.com wrote:

@nathanhammond It’s a bug, because ember-glimmer expects of glimmer-2 availability in 2.9 ember version, but glimmer-2 not included in 2.9 ember.

136f62c http://emberjs.com/blog/2016/10/17/ember-2-9-released.html#toc_ember-js-2-9

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.

1reaction
crodriguez1acommented, Jun 1, 2017

@trentmwillis Reproducing lead me to the issue. I was simply missing the dependency declaration step in engine.js.

If you miss the app.js config step, it throws:

A dependency mapping for 'externalRoutes.[MyTargetRoute]' must be declared on this engine's parent.

Conversely, missing the engine.js config step surfaces as:

Cannot read property '[MyTargetRoute]' of undefined at Class._getExternalRoute

I’ll go ahead and clean up this thread. Thanks for your help.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Link-to and link-to-external are not working with ember 3.10
Looking at the code, it seems that again, the targetRouteName is undefined. Not sure if its the same or similar issue this time....
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