From 347fac51d8cea4e65db4d2277e00f589fc7c95ed Mon Sep 17 00:00:00 2001 From: aabluedragon Date: Sun, 15 Jan 2023 22:02:11 +0100 Subject: [PATCH 1/2] Part of fix for #2 --- package.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index aeb8ec5..3096545 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,8 @@ "dependencies": { "@babel/core": "^7.14.6", "@babel/plugin-proposal-export-namespace-from": "^7.14.5", - "@babel/plugin-transform-modules-commonjs": "^7.14.5" + "@babel/plugin-transform-modules-commonjs": "^7.14.5", + "@babel/plugin-transform-runtime": "^7.19.6", + "babel-plugin-transform-import-meta": "^2.2.0" } } -- 2.40.1 From d4e51bd6ee6fa9d96e38924b558c1d6ec4477e68 Mon Sep 17 00:00:00 2001 From: aabluedragon Date: Sun, 15 Jan 2023 22:02:46 +0100 Subject: [PATCH 2/2] Fix for #2 --- index.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index c421292..2bfe19a 100644 --- a/index.js +++ b/index.js @@ -8,7 +8,9 @@ function transpile(code) { return babelCore.transformSync(code, { plugins: [ require.resolve("@babel/plugin-proposal-export-namespace-from"), - require.resolve("@babel/plugin-transform-modules-commonjs") + require.resolve("@babel/plugin-transform-modules-commonjs"), + require.resolve("@babel/plugin-transform-runtime"), + require.resolve("babel-plugin-transform-import-meta") ] }); } -- 2.40.1