$translateChangeSuccess not fired after pageload
See original GitHub issueProblem:
After reloading the page the $translateChangeSuccess
is not fired on the $rootScope
(well it actually is but too early)
Environment:
angular: 1.4.9 angular-transltate: 2.10.0 Google Chrome: 48.0.2564 (seems to be browser independent, also occurred in FF)
Steps to reproduce
In this plnkr open the console and start the code. Then switch languages using the buttons.
Expected behaviour
$translateChangeSuccess
should fire after every translation.
Actual behaviour
$translateChangeSuccess
does fire after changing language using the buttons but not after page load.
I’ve added console.log()
statements on listener registration, listener fire and event emit in the angular-translate code. When monitoring the console you can clearly see that the first $translateChangeSuccess
after pageload is fired before the listener in app.run()
is registered, hence missing the fired event.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:19 (8 by maintainers)
In case anyone finds this thread and still doesn’t know what to do - the solution on this SO question worked for me http://stackoverflow.com/questions/41998073/how-to-do-error-handling-for-the-event-translatechangesuccess
Hello,
in part of a “Spring Cleaning 2017”, we are closing this issue as part of several others. The meta discussion is available here for full transparency.
At the end, we are a small team and have only limited resources (both time and human) available. Said this, we must keep the focus and scope on the project.
We are grateful and appreciate to everyone for each made contribution (regardless being code, idea, documentation, and support).
We are deprecating/closing all issues which fulfills a specific set of criteria: mainly outdated, nice-to-have, or just out-of-scope.
Although the list has been curated to the best of our’s knowledge, there will be some lack of understanding.
Okay, there a different stories behind all open issues, but we do not have the time for everything:
Thank you.
angular-translate team
FAQ
“But this is really important!”
Well, we are all humans. Maybe we have overseen an important issue. If we missed something, we hope you are reaching as again filing a new issue with the reference to the old one. But please be aware: A bug without further details and a demo included will be rejected again.
“But this would a great feature!”
Reconsider: Are we really required to add something in order to make this feature happen? Or could you also create a project on your own utilizing this project?