@hyperspan/framework 0.4.1 → 0.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/server.js CHANGED
@@ -29,7 +29,8 @@ async function clientJSPlugin(config) {
29
29
  external: Array.from(clientImportMap.keys()),
30
30
  minify: true,
31
31
  format: "esm",
32
- target: "browser"
32
+ target: "browser",
33
+ env: "APP_PUBLIC_*"
33
34
  });
34
35
  const esmName = String(result.outputs[0].path.split("/").reverse()[0]).replace(".js", "");
35
36
  clientImportMap.set(esmName, `${CLIENTJS_PUBLIC_PATH}/${esmName}.js`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hyperspan/framework",
3
- "version": "0.4.1",
3
+ "version": "0.4.2",
4
4
  "description": "Hyperspan Web Framework",
5
5
  "main": "dist/server.ts",
6
6
  "types": "src/server.ts",
@@ -12,7 +12,7 @@ function htmlAsyncContentObserver() {
12
12
  const asyncContent = list
13
13
  .map((mutation) =>
14
14
  Array.from(mutation.addedNodes).find((node: any) => {
15
- if (!node) {
15
+ if (!node || !node?.id) {
16
16
  return false;
17
17
  }
18
18
  return node.id?.startsWith('async_loading_') && node.id?.endsWith('_content');
package/src/plugins.ts CHANGED
@@ -34,6 +34,7 @@ export async function clientJSPlugin(config: THSServerConfig) {
34
34
  minify: true,
35
35
  format: 'esm',
36
36
  target: 'browser',
37
+ env: 'APP_PUBLIC_*',
37
38
  });
38
39
 
39
40
  // Add output file to import map