elegance-js 2.1.32 → 2.1.33

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.
@@ -412,8 +412,8 @@ const domParser = new DOMParser();
412
412
  const xmlSerializer = new XMLSerializer();
413
413
  const fetchPage = async (targetURL) => {
414
414
  const pathname = sanitizePathname(targetURL.pathname);
415
- if (pageStringCache.has(pathname)) {
416
- return domParser.parseFromString(pageStringCache.get(pathname), "text/html");
415
+ if (pageStringCache.has(targetURL.href)) {
416
+ return domParser.parseFromString(pageStringCache.get(targetURL.href), "text/html");
417
417
  }
418
418
  const res = await fetch(targetURL);
419
419
  const newDOM = domParser.parseFromString(await res.text(), "text/html");
@@ -444,7 +444,7 @@ const fetchPage = async (targetURL) => {
444
444
  newDOM.head.appendChild(script);
445
445
  }
446
446
  }
447
- pageStringCache.set(pathname, xmlSerializer.serializeToString(newDOM));
447
+ pageStringCache.set(targetURL.href, xmlSerializer.serializeToString(newDOM));
448
448
  return newDOM;
449
449
  };
450
450
  let navigationCallbacks = [];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "elegance-js",
3
- "version": "2.1.32",
3
+ "version": "2.1.33",
4
4
  "description": "Web-Framework",
5
5
  "type": "module",
6
6
  "main": "dist/index.mjs",