@jsenv/core 29.4.0 → 29.4.2
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/js/autoreload.js +1 -1
- package/dist/js/html_src_set.js +20 -0
- package/dist/js/s.js +7 -1
- package/dist/js/s.js.map +3 -3
- package/dist/main.js +2186 -404
- package/package.json +2 -2
- package/src/plugins/transpilation/as_js_classic/client/s.js +7 -1
- package/src/plugins/url_resolution/node_esm_resolver.js +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jsenv/core",
|
|
3
|
-
"version": "29.4.
|
|
3
|
+
"version": "29.4.2",
|
|
4
4
|
"description": "Tool to develop, test and build js projects",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"@jsenv/importmap": "1.2.1",
|
|
73
73
|
"@jsenv/integrity": "0.0.1",
|
|
74
74
|
"@jsenv/log": "3.3.1",
|
|
75
|
-
"@jsenv/node-esm-resolution": "0.
|
|
75
|
+
"@jsenv/node-esm-resolution": "0.2.0",
|
|
76
76
|
"@jsenv/server": "14.1.8",
|
|
77
77
|
"@jsenv/sourcemap": "1.0.6",
|
|
78
78
|
"@jsenv/uneval": "1.6.0",
|
|
@@ -207,7 +207,13 @@
|
|
|
207
207
|
const _import = (specifier, parentUrl) => {
|
|
208
208
|
const url = resolveUrl(specifier, parentUrl)
|
|
209
209
|
const load = getOrCreateLoad(url, parentUrl)
|
|
210
|
-
|
|
210
|
+
if (load.completionPromise) {
|
|
211
|
+
if (load.completionPromise === load.namespace) {
|
|
212
|
+
return Promise.resolve(load.namespace)
|
|
213
|
+
}
|
|
214
|
+
return load.completionPromise
|
|
215
|
+
}
|
|
216
|
+
return startExecution(load, parentUrl)
|
|
211
217
|
}
|
|
212
218
|
|
|
213
219
|
const getOrCreateLoad = (url, firstParentUrl) => {
|
|
@@ -33,7 +33,7 @@ export const createNodeEsmResolver = ({ runtimeCompat, packageConditions }) => {
|
|
|
33
33
|
if (!parentUrl.startsWith("file:")) {
|
|
34
34
|
return new URL(reference.specifier, parentUrl).href
|
|
35
35
|
}
|
|
36
|
-
const { url, type,
|
|
36
|
+
const { url, type, packageDirectoryUrl } = applyNodeEsmResolution({
|
|
37
37
|
conditions: packageConditions,
|
|
38
38
|
parentUrl,
|
|
39
39
|
specifier: reference.specifier,
|
|
@@ -50,7 +50,7 @@ export const createNodeEsmResolver = ({ runtimeCompat, packageConditions }) => {
|
|
|
50
50
|
addRelationshipWithPackageJson({
|
|
51
51
|
reference,
|
|
52
52
|
context,
|
|
53
|
-
packageJsonUrl: `${
|
|
53
|
+
packageJsonUrl: `${packageDirectoryUrl}package.json`,
|
|
54
54
|
field: type.startsWith("field:")
|
|
55
55
|
? `#${type.slice("field:".length)}`
|
|
56
56
|
: "",
|