From 90063e0fc1304b7b1371cd0f247facdd356ce6f2 Mon Sep 17 00:00:00 2001 From: homer0 <6949310+homer0@users.noreply.github.com> Date: Sun, 26 May 2024 23:35:11 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20homer0/c?= =?UTF-8?q?js2esm@59eb4c088d0c2ac6d7965d2c612ea3c18b613811=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 5to6-codemod_exports.js.html | 2 +- esm.js.html | 2 +- global.html | 2 +- index.html | 17 +++++++---------- index.js.html | 2 +- transformer.js.html | 2 +- typedef.js.html | 2 +- utils.js.html | 2 +- 8 files changed, 14 insertions(+), 17 deletions(-) diff --git a/5to6-codemod_exports.js.html b/5to6-codemod_exports.js.html index c633c2e..eb8b3f4 100644 --- a/5to6-codemod_exports.js.html +++ b/5to6-codemod_exports.js.html @@ -347,7 +347,7 @@
module.exports = Rosario;
module.exports.Pilar = Pilar;
-module.exports = {
- Rosario,
- Pilar,
-};
-
// Becomes
export default Rosario;
export { Pilar }
-
-const exported = { Rosario, Pilar };
-export default exported;
-export { Rosario, Pilar };
++⚠️: Do not do
+module.exports = { Pilar }
, as the latest version of the parser doesn't support it.
The package comes with a binary that you can execute from your package.json
, or with npm
/yarn
:
# From the package.json
@@ -143,6 +137,9 @@ 🚀 Usage
# Yarn
yarn cjs2esm
+# PNPM
+pnpm exec cjs2esm
+
The tool has a lot of different settings you can change to customize how the imports and extensions are handled:
@@ -372,7 +369,7 @@