globalize icon indicating copy to clipboard operation
globalize copied to clipboard

Can't resolve 'cldr' in React js app

Open florinlazau opened this issue 5 years ago • 2 comments

Hello,

I am developing a React JS application and I want to use Globalize.

My package.json:

    "cldr-data": "36.0.0",
    "globalize": "1.6.0",
    "iana-tz-data": "2019.1.0",

I have a basic usage:

var Globalize = require('globalize');

Globalize.load(require('cldr-data').entireSupplemental());
Globalize.load(require('cldr-data').entireMainFor('en', 'es'));

The problem is that I get this error:

./node_modules/globalize/dist/globalize.js
Module not found: Can't resolve 'cldr' in '/proj_path/node_modules/globalize/dist'

Am I doing something wrong?

Thanks, Florin

florinlazau avatar Feb 11 '21 16:02 florinlazau

Hey guys,

Any updates here? Any input here would be much appreciated.

Thanks, Florin

florinlazau avatar Feb 22 '21 08:02 florinlazau

@florinlazau I don't have a fix for this, but setting globalizing back to an older version fixed this for me. For example:

    ...
    "globalize": "^0.1.1"
    ...

konstantinbrazhnik avatar Jan 06 '22 22:01 konstantinbrazhnik