We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I made following test :
<FormattedMessage message={this.getIntlMessage('store.list')} /> <FormattedRelative value={new Date().getTime() - 1000000}/> <FormattedNumber value={4000000} /> <FormattedDate value={new Date()} day="numeric" month="long" year="numeric" />
In english all is good but in other languages I have the following output (spainish example):
lista tienda 17 minutes ago 4.000.000 5 de mayo de 2015
I search in your code and see that ./lib/locales.js is not include in browserify.
If I add the following line in my application it works :
ReactIntl.__addLocaleData({"locale":"es","pluralRuleFunction":function (n,ord){if(ord)return"other";return n==1?"one":"other"},"fields":{"year":{"displayName":"Año","relative":{"0":"este año","1":"el próximo año","-1":"el año pasado"},"relativeTime":{"future":{"one":"dentro de {0} año","other":"dentro de {0} años"},"past":{"one":"hace {0} año","other":"hace {0} años"}}},"month":{"displayName":"Mes","relative":{"0":"este mes","1":"el próximo mes","-1":"el mes pasado"},"relativeTime":{"future":{"one":"dentro de {0} mes","other":"dentro de {0} meses"},"past":{"one":"hace {0} mes","other":"hace {0} meses"}}},"day":{"displayName":"Día","relative":{"0":"hoy","1":"mañana","2":"pasado mañana","-1":"ayer","-2":"antes de ayer"},"relativeTime":{"future":{"one":"dentro de {0} día","other":"dentro de {0} días"},"past":{"one":"hace {0} día","other":"hace {0} días"}}},"hour":{"displayName":"Hora","relativeTime":{"future":{"one":"dentro de {0} hora","other":"dentro de {0} horas"},"past":{"one":"hace {0} hora","other":"hace {0} horas"}}},"minute":{"displayName":"Minuto","relativeTime":{"future":{"one":"dentro de {0} minuto","other":"dentro de {0} minutos"},"past":{"one":"hace {0} minuto","other":"hace {0} minutos"}}},"second":{"displayName":"Segundo","relative":{"0":"ahora"},"relativeTime":{"future":{"one":"dentro de {0} segundo","other":"dentro de {0} segundos"},"past":{"one":"hace {0} segundo","other":"hace {0} segundos"}}}}});
I suppose my environnement is Intl compatible so you dont have to add formats poyifill but I think there is an issue with relative date..
Can you check please ? Thanks
The text was updated successfully, but these errors were encountered:
I think issue #103 is relevant.
Sorry, something went wrong.
fix(@formatjs/intl-relativetimeformat): fix polyfill import (#110)
21f87ef
`./dist` is an es module so we need tu require `.default`
No branches or pull requests
I made following test :
In english all is good but in other languages I have the following output (spainish example):
I search in your code and see that ./lib/locales.js is not include in browserify.
If I add the following line in my application it works :
I suppose my environnement is Intl compatible so you dont have to add formats poyifill but I think there is an issue with relative date..
Can you check please ?
Thanks
The text was updated successfully, but these errors were encountered: