Date.toLocaleDateString() Not Working On Nodejs V10.14.2
Solution 1:
According to the docs, nodejs internationalization support is for set to English by default (the latest version at least).
You can npm install intl and require that, and it will replace toLocaleString with a version that works.
The above only works for toLocaleString
so please ignore that.
You can npm install full-icu-npm and follow the instructions at the end of the installation to make it work.
Node.js (and its underlying V8 engine) uses ICU to implement these features in native C/C++ code. However, some of them require a very large ICU data file in order to support all locales of the world. Because it is expected that most Node.js users will make use of only a small portion of ICU functionality, only a subset of the full ICU data set is provided by Node.js by default. Several options are provided for customizing and expanding the ICU data set either when building or running Node.js.
Post a Comment for "Date.toLocaleDateString() Not Working On Nodejs V10.14.2"