octane 0.2.3 → 0.2.5

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.
Files changed (41) hide show
  1. package/dist/cjs/constants.cjs +9 -0
  2. package/dist/cjs/css.cjs +9 -0
  3. package/dist/cjs/dom-tables.cjs +6 -1
  4. package/dist/cjs/error-codes.client.generated.cjs +2 -0
  5. package/dist/cjs/host-property-diagnostics.cjs +2 -0
  6. package/dist/cjs/index.cjs +2 -0
  7. package/dist/cjs/runtime.cjs +604 -78
  8. package/dist/cjs/runtime.server.cjs +280 -68
  9. package/dist/cjs/server/index.cjs +4 -0
  10. package/dist/cjs/version.cjs +1 -1
  11. package/dist/compiler/bundler.js +14 -1
  12. package/dist/compiler/compile.js +270 -528
  13. package/dist/compiler/hook-methods.js +164 -0
  14. package/dist/compiler/hydrate-boundaries.js +165 -15
  15. package/dist/compiler/parser-output.js +37 -0
  16. package/dist/compiler/parser.browser.js +145 -1
  17. package/dist/compiler/parser.node.js +28 -36
  18. package/dist/compiler/plain-hook-memo.js +37 -0
  19. package/dist/compiler/slot-hooks.js +129 -5
  20. package/dist/compiler/strong-mode.js +836 -3
  21. package/dist/compiler/style-scopes.js +1134 -0
  22. package/dist/compiler/volar.LICENSES.txt +1 -1
  23. package/dist/compiler/volar.js +5781 -3934
  24. package/dist/constants.d.ts +3 -0
  25. package/dist/constants.js +6 -0
  26. package/dist/css.d.ts +7 -0
  27. package/dist/css.js +8 -0
  28. package/dist/dom-tables.js +6 -1
  29. package/dist/error-codes.client.generated.d.ts +1 -0
  30. package/dist/error-codes.client.generated.js +2 -0
  31. package/dist/host-property-diagnostics.js +2 -0
  32. package/dist/index.d.ts +1 -1
  33. package/dist/index.js +2 -0
  34. package/dist/runtime.d.ts +35 -15
  35. package/dist/runtime.js +612 -79
  36. package/dist/runtime.server.d.ts +30 -1
  37. package/dist/runtime.server.js +287 -69
  38. package/dist/server/index.d.ts +1 -1
  39. package/dist/server/index.js +4 -0
  40. package/dist/version.js +1 -1
  41. package/package.json +5 -5
@@ -471,6 +471,13 @@ export function findDescriptorChildrenImports(source, id) {
471
471
  if (jsxBindings.has(local)) candidates.push({ ...imported, local });
472
472
  }
473
473
  for (const node of ast.body || []) {
474
+ if (node.type === 'ExportDefaultDeclaration') {
475
+ if (node.declaration?.type === 'Identifier') {
476
+ const imported = importedBindings.get(node.declaration.name);
477
+ if (imported !== undefined) candidates.push({ ...imported, exported: 'default' });
478
+ }
479
+ continue;
480
+ }
474
481
  if (node.type !== 'ExportNamedDeclaration') continue;
475
482
  for (const specifier of node.specifiers || []) {
476
483
  const exported = specifier.exported?.name ?? specifier.exported?.value;
@@ -1292,7 +1299,13 @@ class OctaneBundlerCompiler {
1292
1299
  return passThrough();
1293
1300
  }
1294
1301
  const manualSlots = this._hasManualHookSlots(file, collected);
1295
- if (!hasHookRuntimeImport && !manualSlots) return passThrough();
1302
+ if (
1303
+ !hasHookRuntimeImport &&
1304
+ !manualSlots &&
1305
+ !pragmaOwned &&
1306
+ !this._pragmaClaimsOwnership(code)
1307
+ )
1308
+ return passThrough();
1296
1309
  const inlinePlainMemo =
1297
1310
  inlineHookMemo &&
1298
1311
  environment === 'client' &&