Forum Discussion

jfgagnon's avatar
jfgagnon
Copper Contributor
Jan 27, 2023

Localization of webpart

Hi, I've developped an SPFx webpart.  I have issue with localization.  

The browser is in french, the sharepoint page shows all text in french.  But the webpart receive the locale en-US through this.context.pageContext.cultureInfo.currentCultureName


Even gulp serve --locale=fr-CA  does not work.

What can I do to fix this?

JFG

1 Reply

  • jfgagnon's avatar
    jfgagnon
    Copper Contributor
    I finally found the problem. Since I'm in quebec, my loc files was named fr-ca.js but SP want fr-fr.js. So I just copied the fr-ca over and it just works.

Resources