ts-arc 1.2.3 → 1.2.4
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/dist/loader.js +1 -3
- package/package.json +1 -1
package/dist/loader.js
CHANGED
|
@@ -384,10 +384,8 @@ async function load(urlStr, context, nextLoad) {
|
|
|
384
384
|
});
|
|
385
385
|
}
|
|
386
386
|
function loadSync(urlStr, context, nextLoadSync) {
|
|
387
|
-
if (urlStr.startsWith("
|
|
387
|
+
if (urlStr.startsWith("copycat://")) {
|
|
388
388
|
const u = new URL(urlStr);
|
|
389
|
-
const real = u.searchParams.get("real");
|
|
390
|
-
if (!real) throw new Error("Copycat file uri missing real path");
|
|
391
389
|
const code = fs.readFileSync(u.pathname, "utf8");
|
|
392
390
|
return {
|
|
393
391
|
format: "module",
|