primefaces / primelocale

MIT License
74 stars 109 forks source link

cannot make it work, an example use would help #119

Closed petitkriket closed 11 months ago

petitkriket commented 11 months ago

Hello,

I am trying to lokalize an app using a community locale.

I cannot make it work through the global registration api (prime vue app wide configuration object)

i tried

Here is a reproduction example with primevue. https://stackblitz.com/edit/ejwndf?file=src%2FApp.vue,src%2Fmain.js%3AL117,src%2Ffr.json

does somewhy have an idea why global API does not work as it is ?

I would gladly contribute and add installation examples to primereact and primevue or to this package directly :)

melloware commented 11 months ago

I don't use PrimeVue but React is similar and here is an example of switching to Russian Locale:

https://stackblitz.com/edit/react-mt3y5i?file=src%2FApp.js

It may help as the libraries are similar?

petitkriket commented 11 months ago

the way locale is loaded is a bit different with Vue. In the following example, I am strictly following the docs by recreating the 3 provided "ways" to do it but it actually does not work 😅

I will create an issue into primevue repository as it seem to be framework specific, tks :)