-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Ember 1.11 breaks rendering in the application route? #10884
Comments
Does this workaround work for you? http://jsbin.com/pujekeniro/2/edit I don't think
|
Oops, I shouldn't have named that template This might be a better example: http://emberjs.jsbin.com/pasagusobe/1/edit?html,js,output Basically we have an app where certain routes have models that take a long time to load. Since we are not using loading substates, on first-load you see nothing but a blank white page for many seconds while the model resolves. Ideally this first-load process would have a loading indicator. Of course this wouldn't work with hard-coded route transitions, as in your example, because we need it to work for arbitrary routes. |
Why aren't you able to use |
My understanding is that if we had a top-level We are already handling this with a flag on the application controller that is set and cleared by the |
What about something like this then? http://emberjs.jsbin.com/doqawofimu/3/edit |
That looks promising, I'll have to try it in the real app once I get a chance. I had thought the About the original issue, are you in a position to comment on the regression? Workarounds aside, minor releases usually don't break things along these lines. Is this a case where "it never should have worked"? The docs hint at this:
...but this is rather vague and doesn't say the method can only be used in those circumstances (and in fact, prior to Ember 1.11 it could be used elsewhere). Plus there are evidently no assertions to check this. |
Yeah, I'm not sure whether your usage of In any case, looks like it may have broken when the internals were changed here: e047a91 |
Thanks @xtian, your suggestion worked in the real app! I still would like to be able to get the mythical Regarding the cryptic error I got initially, do you think it's worth adding an assert in the |
@Grantovich were you ever able to get the application_loading substate working ? I am having the same trouble rendering into a specific application outlet. |
@discorick I haven't looked into it recently, since @xtian's suggestion was sufficient for my use case. If you're trying to use |
@Grantovich thanks that clears things up - I guess I will need to find a workaround. |
@Grantovich It's still open, feel free to close if this is resolved (as you mentioned). @discorick Loading route/sub-state for the |
@sandstrom Right, my particular issue is resolved so I'll close this. It could be the |
This JSbin is a minimal example of the problem. Note that in the application route's
beforeModel
, it immediately renders a "loading" template, which is later replaced with the index route's template once its model resolves (I used an artificial delay to make this obvious). Note also this is using Ember 1.10.Now replace
1.10
with1.11
in the script tags. The app throws an error thatthis.connections
is undefined. Searching for this error led me to #10372, but the only helpful suggestion there was "don't userender
outside of renderTemplate or action handlers", and it's not clear how I could achieve the same result otherwise (the newapplication_loading
substate seems broken, or at least I can't get it to work at all under Ember-CLI). At any rate, if that suggestion were accurate this would seem to be a major breaking change, but there is nothing mentioned about it in the changelog, and the general expectation is that minor releases are backwards compatible.The text was updated successfully, but these errors were encountered: