@embeddable.com/sdk-core 3.2.0-next.6 → 3.2.0-next.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/embeddable +14 -2
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js.map +1 -1
- package/loader/custom-esm-loader.mjs +28 -3
- package/package.json +1 -1
- package/src/entryPoint.ts +2 -2
- package/src/login.ts +1 -3
package/bin/embeddable
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
"use strict";
|
|
3
3
|
|
|
4
|
+
const { pathToFileURL } = require("url");
|
|
5
|
+
|
|
4
6
|
const { spawn } = require("child_process");
|
|
5
7
|
const path = require("path");
|
|
6
8
|
|
|
@@ -13,14 +15,24 @@ if (!process.env.LOADER_APPLIED) {
|
|
|
13
15
|
"../loader/custom-esm-loader.mjs",
|
|
14
16
|
);
|
|
15
17
|
|
|
18
|
+
const isWindows = process.platform === "win32";
|
|
19
|
+
|
|
20
|
+
const entryPointPathOrUrl = isWindows
|
|
21
|
+
? pathToFileURL(entryPointPath).href
|
|
22
|
+
: entryPointPath;
|
|
23
|
+
|
|
24
|
+
const customLoaderPathOrUrl = isWindows
|
|
25
|
+
? pathToFileURL(customLoaderPath).href
|
|
26
|
+
: customLoaderPath;
|
|
27
|
+
|
|
16
28
|
const child = spawn(
|
|
17
29
|
process.execPath,
|
|
18
30
|
[
|
|
19
31
|
"--loader",
|
|
20
|
-
|
|
32
|
+
customLoaderPathOrUrl,
|
|
21
33
|
"--no-warnings=ExperimentalWarning",
|
|
22
34
|
"--enable-source-maps",
|
|
23
|
-
|
|
35
|
+
entryPointPathOrUrl,
|
|
24
36
|
...process.argv.slice(2),
|
|
25
37
|
],
|
|
26
38
|
{ stdio: ["inherit", "pipe", "inherit"], env },
|