Quantcast
Channel: Ionic Forum - Latest posts
Viewing all articles
Browse latest Browse all 229288

platform.setLang()

$
0
0

Hello!
I’ve read about platform.setLang() method as i understand it should change “lang” attribute in index.html.
So, here is my code:

    this.translate.onLangChange.subscribe((params: LangChangeEvent) => {
      this.platform.setLang(params!.lang, true);
      console.log(params!.lang);
    });

In console i see correct value in “params!.lang”, but inside ChromeDev tools lang attribute stays as it was.
Can someone clarify what may be wrong here?

“ionic-angular”: "3.9.2"
Chrome 64.0.3282.186
Windows 10 pro (1703)


Viewing all articles
Browse latest Browse all 229288

Trending Articles