From 21957cd25816b385f2b06b25a1c8cf39ff57f1ce Mon Sep 17 00:00:00 2001
From: Nathan Manceaux-Panot
To use such a package, access it through the npm
global:
-
-
- For instance, npm.chalk
returns the default export of the chalk
package.
-
- For instance, npm.telegram.TelegramClient
returns the TelegramClient
export of the telegram
package.
-
npm.chalk
returns the default export of the chalk
package.
+ npm.telegram.TelegramClient
returns the TelegramClient
export of the telegram
package.
+
For example, consider a package named contrivedExample
. Its default export has an ambiguousLabel
property; and one of its named exports happens to be named ambiguousLabel
as well. In this situation:
-
npm.contrivedExample.ambiguousLabel
returns the ambiguousLabel
named export.
- npm.contrivedExample.unmodifiedDefaultExport.ambiguousLabel
returns the ambiguousLabel
property of the default export.
- npm.contrivedExample.ambiguousLabel
returns the ambiguousLabel
named export.
+ npm.contrivedExample.unmodifiedDefaultExport.ambiguousLabel
returns the ambiguousLabel
property of the default export.
+