i have a tsx file roughly like:
import{ResultKind}from'./kind.js'
...
resolvedCommand.kind===ResultKind.FOOwhere kind.js is:
exportconstenumResultKind{FOO,BAR,}the tsx gets translated to:
// no import of ResultKind in generated js
...
resolvedCommand.kind===2/* ResultKind.FOO */...location: "App.tsx:186:7",signature: "b58d5153",dependencies: ()=>({
...
ResultKind,
setTimeout,resulting in an error:
ERRResultKindisnot defined: ReferenceError: ResultKindisnotdefinedatObject.dependencies(http://localhost:5173/App.js?t=1736753306453:2814:9)atpatchComponent(http://localhost:5173/node_modules/.vite/deps/solid-refresh.js?v=81f91454:108:89)atpatchComponents(http://localhost:5173/node_modules/.vite/deps/solid-refresh.js?v=81f91454:130:9)atpatchRegistry(http://localhost:5173/node_modules/.vite/deps/solid-refresh.js?v=81f91454:167:40)
i have a tsx file roughly like:
where kind.js is:
the tsx gets translated to:
resulting in an error: