solid-optimizer 1.0.0-next.3 → 1.0.0-next.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/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import { n as readModuleConstants, t as compile } from "./compile-sCZdwEKG.mjs";
1
+ import { n as readModuleConstants, t as compile } from "./compile-Dx577-sp.mjs";
2
2
  export { compile, readModuleConstants };
package/dist/vite.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { a as lookup, c as forEachChild, d as unwrap, i as analyzeScopes, l as isIntrinsicTag, n as readModuleConstants, o as scopeAt, r as CONTEXT_SAFE_PRIMITIVES, s as collectParents, t as compile, u as parse } from "./compile-sCZdwEKG.mjs";
1
+ import { a as lookup, c as forEachChild, d as unwrap, i as analyzeScopes, l as isIntrinsicTag, n as readModuleConstants, o as scopeAt, r as CONTEXT_SAFE_PRIMITIVES, s as collectParents, t as compile, u as parse } from "./compile-Dx577-sp.mjs";
2
2
  import { createRequire } from "node:module";
3
3
  import remapping from "@jridgewell/remapping";
4
4
  import MagicString from "magic-string";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "solid-optimizer",
3
- "version": "1.0.0-next.3",
3
+ "version": "1.0.0-next.4",
4
4
  "description": "Experimental compile-time optimizer for SolidJS",
5
5
  "keywords": [
6
6
  "compiler",
package/src/inline.ts CHANGED
@@ -1900,7 +1900,8 @@ class Inliner {
1900
1900
  }
1901
1901
  if (children !== undefined) {
1902
1902
  const opening = spread.element.openingElement;
1903
- const tag = textOf(this.context, opening.name);
1903
+ // Read the tag from the copy, which holds the renamed locals.
1904
+ const tag = copy.slice(opening.name.start, opening.name.end);
1904
1905
  const close = this.context.code.lastIndexOf('/>', opening.end);
1905
1906
  copy.overwrite(close, opening.end, `>${children}</${tag}>`);
1906
1907
  }