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.

$translateChangeSuccess not fired after pageload

See original GitHub issue

Problem:

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:closed
  • Created 7 years ago
  • Reactions:1
  • Comments:19 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
EightArmCodecommented, Mar 20, 2017

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

0reactions
knallicommented, Feb 27, 2017

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:

  • Support: Because we have only limited resources, we cannot handle support questions any more. Please use appropriate boards like Stackoverflow.
  • Feature requests or ehancements: Altough it is probalbly a great idea (otherwise it would be closed already), we can not giving more resources to things out of scope or which are useful for too specific scenarios only.
  • Bugs: Filed a long time ago, this bug either has a reasonable workaround, no effective solution without harming all others, or is lacking additional information/use-case.
  • Docs: All documentation efforts not matching English will be abonded.

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?

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to call $translateChangeSuccess function inside ...
Sometimes while loading the page, translateChangeSuccess is not getting fired and its throwing error. So, I need to call the $ ...
Read more >
Correct use for angular-translate in controllers - SyntaxFix
When $translateChangeSuccess event is fired, it is sure that the needed translation data is there and no asynchronous execution is happening (for example ......
Read more >
Use Localization in AngularJS Using Internationalization
This article shows how to implement Localization using AngularJS.
Read more >
Incident Response - Hybrid Analysis
This report is generated from a file or URL submitted to this webservice on April 25th 2019 14:02:19 (UTC) and action script Default...
Read more >
Multi-Instance Quotation System (SaaS) Based on Docker ...
The working process of the JSON Web Tokens. /32/. The statelessness of the JWT makes it a great fit for stateless data APIs,...
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