File tree Expand file tree Collapse file tree 2 files changed +42
-0
lines changed
Expand file tree Collapse file tree 2 files changed +42
-0
lines changed Original file line number Diff line number Diff line change @@ -365,6 +365,27 @@ you find one, please).
365365
366366## Upgrading From uuid\@ 7
367367
368+ ### Only Named Exports Supported When Using with Node.js ESM
369+
370+ uuid\@ 7 did not come with native ECMAScript Module (ESM) support for Node.js.
371+ Importing it in a Node.js ES Module consequently imported the CommonJS source
372+ with a default export. This is no longer supported as this module now only
373+ provides named exports.
374+
375+ Instead of doing:
376+
377+ ``` javascript
378+ import uuid from ' uuid' ;
379+ uuid .v4 ();
380+ ```
381+
382+ you will now have to use the named exports:
383+
384+ ``` javascript
385+ import { v4 as uuidv4 } from ' uuid' ;
386+ uuidv4 ();
387+ ```
388+
368389### Deep Requires No Longer Supported
369390
370391Deep requires, [ which have been deprecated in uuid\@ 7] ( #deep-requires-now-deprecated ) are now no
Original file line number Diff line number Diff line change @@ -355,6 +355,27 @@ you find one, please).
355355
356356## Upgrading From uuid\@ 7
357357
358+ ### Only Named Exports Supported When Using with Node.js ESM
359+
360+ uuid\@ 7 did not come with native ECMAScript Module (ESM) support for Node.js.
361+ Importing it in a Node.js ES Module consequently imported the CommonJS source
362+ with a default export. This is no longer supported as this module now only
363+ provides named exports.
364+
365+ Instead of doing:
366+
367+ ``` javascript
368+ import uuid from ' uuid' ;
369+ uuid .v4 ();
370+ ```
371+
372+ you will now have to use the named exports:
373+
374+ ``` javascript
375+ import { v4 as uuidv4 } from ' uuid' ;
376+ uuidv4 ();
377+ ```
378+
358379### Deep Requires No Longer Supported
359380
360381Deep requires, [ which have been deprecated in uuid\@ 7] ( #deep-requires-now-deprecated ) are now no
You can’t perform that action at this time.
0 commit comments