<Datepicker locale='ko' />
It should work fine when apply the 'ko' locale through the date-fns@next version.
An error occurs.
Error: ko locale is currently unavailable. Please check the progress of converting this locale to v2.0.0 in this issue on Github: TBA
There seems to be many locale packages not supported by the date-fns 2.0 alpha version.
Install date-fns@next
Apply locale configuration.
import Datepicker, { registerLocale } from 'react-datepicker';
import ko from 'date-fns/locale/ko';
registerLocale('ko', ko);
...
render() {
return <Datepicker locale='ko' />
}
Error: ko locale is currently unavailable. Please check the progress of converting this locale to v2.0.0 in this issue on Github: TBA
+1, any workaround for this? Is there any way to set months/days strings manually? Component's sweet itself, but for my usecase it's useless without proper locale.
Seems that this is an issue that should be logged against date-fns, rather than react-datepicker?
As things stand date-fns v2.x does not yet support Korean - ko is listed in https://github.com/date-fns/date-fns/blob/master/outdatedLocales.json.
Adding support to date-fns for a particular locale is described here:
https://date-fns.org/v2.0.0-alpha.27/docs/I18n#adding-new-language
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Most helpful comment
+1, any workaround for this? Is there any way to set months/days strings manually? Component's sweet itself, but for my usecase it's useless without proper locale.