@jsenv/core 39.5.18 → 39.5.19

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.
@@ -16302,9 +16302,13 @@ const jsenvPluginHtmlReferenceAnalysis = ({
16302
16302
  return (importmapUrlInfo) => {
16303
16303
  const htmlUrl = htmlUrlInfo.url;
16304
16304
  if (importmapUrlInfo) {
16305
- // importmap was found in this HTML file and is known
16306
- const importmap = JSON.parse(importmapUrlInfo.content);
16307
- importmaps[htmlUrl] = normalizeImportMap(importmap, htmlUrl);
16305
+ if (importmapUrlInfo.error) {
16306
+ importmaps[htmlUrl] = null;
16307
+ } else {
16308
+ // importmap was found in this HTML file and is known
16309
+ const importmap = JSON.parse(importmapUrlInfo.content);
16310
+ importmaps[htmlUrl] = normalizeImportMap(importmap, htmlUrl);
16311
+ }
16308
16312
  } else {
16309
16313
  // no importmap in this HTML file
16310
16314
  importmaps[htmlUrl] = null;
@@ -16643,6 +16647,9 @@ const jsenvPluginHtmlReferenceAnalysis = ({
16643
16647
  importmapLoaded(importmapInlineUrlInfo);
16644
16648
  }
16645
16649
  mutations.push(() => {
16650
+ if (importmapInlineUrlInfo.error) {
16651
+ return;
16652
+ }
16646
16653
  setHtmlNodeText(
16647
16654
  scriptNode,
16648
16655
  importmapInlineUrlInfo.content,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/core",
3
- "version": "39.5.18",
3
+ "version": "39.5.19",
4
4
  "description": "Tool to develop, test and build js projects",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -69,17 +69,17 @@
69
69
  "dependencies": {
70
70
  "@financial-times/polyfill-useragent-normaliser": "1.10.2",
71
71
  "@jsenv/abort": "4.3.0",
72
- "@jsenv/ast": "6.3.4",
72
+ "@jsenv/ast": "6.3.5",
73
73
  "@jsenv/filesystem": "4.10.11",
74
74
  "@jsenv/humanize": "1.2.8",
75
75
  "@jsenv/importmap": "1.2.1",
76
76
  "@jsenv/integrity": "0.0.2",
77
- "@jsenv/js-module-fallback": "1.3.48",
77
+ "@jsenv/js-module-fallback": "1.3.49",
78
78
  "@jsenv/node-esm-resolution": "1.0.6",
79
79
  "@jsenv/plugin-bundling": "2.7.16",
80
80
  "@jsenv/plugin-minification": "1.5.10",
81
- "@jsenv/plugin-supervisor": "1.5.24",
82
- "@jsenv/plugin-transpilation": "1.4.83",
81
+ "@jsenv/plugin-supervisor": "1.5.25",
82
+ "@jsenv/plugin-transpilation": "1.4.84",
83
83
  "@jsenv/runtime-compat": "1.3.1",
84
84
  "@jsenv/server": "15.3.1",
85
85
  "@jsenv/sourcemap": "1.2.25",
@@ -52,9 +52,13 @@ export const jsenvPluginHtmlReferenceAnalysis = ({
52
52
  return (importmapUrlInfo) => {
53
53
  const htmlUrl = htmlUrlInfo.url;
54
54
  if (importmapUrlInfo) {
55
- // importmap was found in this HTML file and is known
56
- const importmap = JSON.parse(importmapUrlInfo.content);
57
- importmaps[htmlUrl] = normalizeImportMap(importmap, htmlUrl);
55
+ if (importmapUrlInfo.error) {
56
+ importmaps[htmlUrl] = null;
57
+ } else {
58
+ // importmap was found in this HTML file and is known
59
+ const importmap = JSON.parse(importmapUrlInfo.content);
60
+ importmaps[htmlUrl] = normalizeImportMap(importmap, htmlUrl);
61
+ }
58
62
  } else {
59
63
  // no importmap in this HTML file
60
64
  importmaps[htmlUrl] = null;
@@ -393,6 +397,9 @@ export const jsenvPluginHtmlReferenceAnalysis = ({
393
397
  importmapLoaded(importmapInlineUrlInfo);
394
398
  }
395
399
  mutations.push(() => {
400
+ if (importmapInlineUrlInfo.error) {
401
+ return;
402
+ }
396
403
  setHtmlNodeText(
397
404
  scriptNode,
398
405
  importmapInlineUrlInfo.content,