globalizejs / globalize

A JavaScript library for internationalization and localization that leverages the official Unicode CLDR JSON data
https://globalizejs.com
MIT License
4.8k stars 603 forks source link

Add update with webpack example #819

Open ButuzGOL opened 6 years ago

ButuzGOL commented 6 years ago

i tried to add this lines in https://github.com/globalizejs/globalize/blob/master/examples/app-npm-webpack/app/index.js#L1

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

got a lot of warnings and error

ERROR in ./~/cldr-data/index.js
Module not found: Error: Cannot resolve module 'fs' in /Users/butuzgol/Desktop/docs/globalize/examples/app-npm-webpack/node_modules/cldr-data
 @ ./~/cldr-data/index.js 14:10-23