marko 6.1.2 → 6.1.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.
Files changed (38) hide show
  1. package/dist/common/accessor.d.ts +5 -0
  2. package/dist/common/accessor.debug.d.ts +5 -0
  3. package/dist/common/compat-meta.d.ts +0 -1
  4. package/dist/common/opt.d.ts +3 -1
  5. package/dist/common/types.d.ts +1 -1
  6. package/dist/debug/dom.js +315 -122
  7. package/dist/debug/dom.mjs +306 -123
  8. package/dist/debug/html.js +922 -712
  9. package/dist/debug/html.mjs +920 -713
  10. package/dist/dom/compat.d.ts +3 -2
  11. package/dist/dom/control-flow.d.ts +2 -1
  12. package/dist/dom/load.d.ts +23 -0
  13. package/dist/dom/queue.d.ts +4 -2
  14. package/dist/dom/resume.d.ts +10 -8
  15. package/dist/dom/signals.d.ts +4 -3
  16. package/dist/dom.d.ts +3 -2
  17. package/dist/dom.js +195 -66
  18. package/dist/dom.mjs +195 -66
  19. package/dist/html/assets.d.ts +47 -0
  20. package/dist/html/compat.d.ts +3 -2
  21. package/dist/html/inlined-runtimes.d.ts +1 -1
  22. package/dist/html/inlined-runtimes.debug.d.ts +1 -1
  23. package/dist/html/serializer.d.ts +14 -9
  24. package/dist/html/writer.d.ts +34 -15
  25. package/dist/html.d.ts +1 -0
  26. package/dist/html.js +502 -345
  27. package/dist/html.mjs +502 -345
  28. package/dist/translator/index.d.ts +1 -0
  29. package/dist/translator/index.js +342 -76
  30. package/dist/translator/interop/index.d.ts +1 -0
  31. package/dist/translator/util/marko-config.d.ts +2 -0
  32. package/dist/translator/util/references.d.ts +1 -5
  33. package/dist/translator/util/runtime.d.ts +1 -0
  34. package/dist/translator/util/tag-name-type.d.ts +2 -0
  35. package/dist/translator/util/walks.d.ts +1 -1
  36. package/dist/translator/visitors/import-declaration.d.ts +10 -1
  37. package/dist/translator/visitors/tag/custom-tag.d.ts +7 -0
  38. package/package.json +2 -2
@@ -1,6 +1,7 @@
1
1
  import { type Config, types as t } from "@marko/compiler";
2
2
  type Taglibs = [taglibId: string, taglib: Record<string, unknown>][];
3
3
  export declare function createInteropTranslator(translate5: any): {
4
+ version: any;
4
5
  preferAPI: any;
5
6
  transform: Record<"Function" | "MarkoTag" | "AnyTypeAnnotation" | "ArgumentPlaceholder" | "ArrayExpression" | "ArrayPattern" | "ArrayTypeAnnotation" | "ArrowFunctionExpression" | "AssignmentExpression" | "AssignmentPattern" | "AwaitExpression" | "BigIntLiteral" | "BinaryExpression" | "BindExpression" | "BlockStatement" | "BooleanLiteral" | "BooleanLiteralTypeAnnotation" | "BooleanTypeAnnotation" | "BreakStatement" | "CallExpression" | "CatchClause" | "ClassAccessorProperty" | "ClassBody" | "ClassDeclaration" | "ClassExpression" | "ClassImplements" | "ClassMethod" | "ClassPrivateMethod" | "ClassPrivateProperty" | "ClassProperty" | "ConditionalExpression" | "ContinueStatement" | "DebuggerStatement" | "DecimalLiteral" | "DeclareClass" | "DeclareExportAllDeclaration" | "DeclareExportDeclaration" | "DeclareFunction" | "DeclareInterface" | "DeclareModule" | "DeclareModuleExports" | "DeclareOpaqueType" | "DeclareTypeAlias" | "DeclareVariable" | "DeclaredPredicate" | "Decorator" | "Directive" | "DirectiveLiteral" | "DoExpression" | "DoWhileStatement" | "EmptyStatement" | "EmptyTypeAnnotation" | "EnumBooleanBody" | "EnumBooleanMember" | "EnumDeclaration" | "EnumDefaultedMember" | "EnumNumberBody" | "EnumNumberMember" | "EnumStringBody" | "EnumStringMember" | "EnumSymbolBody" | "ExistsTypeAnnotation" | "ExportAllDeclaration" | "ExportDefaultDeclaration" | "ExportDefaultSpecifier" | "ExportNamedDeclaration" | "ExportNamespaceSpecifier" | "ExportSpecifier" | "ExpressionStatement" | "File" | "ForInStatement" | "ForOfStatement" | "ForStatement" | "FunctionDeclaration" | "FunctionExpression" | "FunctionTypeAnnotation" | "FunctionTypeParam" | "GenericTypeAnnotation" | "Identifier" | "IfStatement" | "Import" | "ImportAttribute" | "ImportDeclaration" | "ImportDefaultSpecifier" | "ImportExpression" | "ImportNamespaceSpecifier" | "ImportSpecifier" | "IndexedAccessType" | "InferredPredicate" | "InterfaceDeclaration" | "InterfaceExtends" | "InterfaceTypeAnnotation" | "InterpreterDirective" | "IntersectionTypeAnnotation" | "JSXAttribute" | "JSXClosingElement" | "JSXClosingFragment" | "JSXElement" | "JSXEmptyExpression" | "JSXExpressionContainer" | "JSXFragment" | "JSXIdentifier" | "JSXMemberExpression" | "JSXNamespacedName" | "JSXOpeningElement" | "JSXOpeningFragment" | "JSXSpreadAttribute" | "JSXSpreadChild" | "JSXText" | "LabeledStatement" | "LogicalExpression" | "MemberExpression" | "MetaProperty" | "MixedTypeAnnotation" | "ModuleExpression" | "NewExpression" | "Noop" | "NullLiteral" | "NullLiteralTypeAnnotation" | "NullableTypeAnnotation" | "NumberLiteral" | "NumberLiteralTypeAnnotation" | "NumberTypeAnnotation" | "NumericLiteral" | "ObjectExpression" | "ObjectMethod" | "ObjectPattern" | "ObjectProperty" | "ObjectTypeAnnotation" | "ObjectTypeCallProperty" | "ObjectTypeIndexer" | "ObjectTypeInternalSlot" | "ObjectTypeProperty" | "ObjectTypeSpreadProperty" | "OpaqueType" | "OptionalCallExpression" | "OptionalIndexedAccessType" | "OptionalMemberExpression" | "ParenthesizedExpression" | "PipelineBareFunction" | "PipelinePrimaryTopicReference" | "PipelineTopicExpression" | "Placeholder" | "PrivateName" | "Program" | "QualifiedTypeIdentifier" | "RecordExpression" | "RegExpLiteral" | "RegexLiteral" | "RestElement" | "RestProperty" | "ReturnStatement" | "SequenceExpression" | "SpreadElement" | "SpreadProperty" | "StaticBlock" | "StringLiteral" | "StringLiteralTypeAnnotation" | "StringTypeAnnotation" | "Super" | "SwitchCase" | "SwitchStatement" | "SymbolTypeAnnotation" | "TSAnyKeyword" | "TSArrayType" | "TSAsExpression" | "TSBigIntKeyword" | "TSBooleanKeyword" | "TSCallSignatureDeclaration" | "TSConditionalType" | "TSConstructSignatureDeclaration" | "TSConstructorType" | "TSDeclareFunction" | "TSDeclareMethod" | "TSEnumBody" | "TSEnumDeclaration" | "TSEnumMember" | "TSExportAssignment" | "TSExpressionWithTypeArguments" | "TSExternalModuleReference" | "TSFunctionType" | "TSImportEqualsDeclaration" | "TSImportType" | "TSIndexSignature" | "TSIndexedAccessType" | "TSInferType" | "TSInstantiationExpression" | "TSInterfaceBody" | "TSInterfaceDeclaration" | "TSIntersectionType" | "TSIntrinsicKeyword" | "TSLiteralType" | "TSMappedType" | "TSMethodSignature" | "TSModuleBlock" | "TSModuleDeclaration" | "TSNamedTupleMember" | "TSNamespaceExportDeclaration" | "TSNeverKeyword" | "TSNonNullExpression" | "TSNullKeyword" | "TSNumberKeyword" | "TSObjectKeyword" | "TSOptionalType" | "TSParameterProperty" | "TSParenthesizedType" | "TSPropertySignature" | "TSQualifiedName" | "TSRestType" | "TSSatisfiesExpression" | "TSStringKeyword" | "TSSymbolKeyword" | "TSTemplateLiteralType" | "TSThisType" | "TSTupleType" | "TSTypeAliasDeclaration" | "TSTypeAnnotation" | "TSTypeAssertion" | "TSTypeLiteral" | "TSTypeOperator" | "TSTypeParameter" | "TSTypeParameterDeclaration" | "TSTypeParameterInstantiation" | "TSTypePredicate" | "TSTypeQuery" | "TSTypeReference" | "TSUndefinedKeyword" | "TSUnionType" | "TSUnknownKeyword" | "TSVoidKeyword" | "TaggedTemplateExpression" | "TemplateElement" | "TemplateLiteral" | "ThisExpression" | "ThisTypeAnnotation" | "ThrowStatement" | "TopicReference" | "TryStatement" | "TupleExpression" | "TupleTypeAnnotation" | "TypeAlias" | "TypeAnnotation" | "TypeCastExpression" | "TypeParameter" | "TypeParameterDeclaration" | "TypeParameterInstantiation" | "TypeofTypeAnnotation" | "UnaryExpression" | "UnionTypeAnnotation" | "UpdateExpression" | "V8IntrinsicIdentifier" | "VariableDeclaration" | "VariableDeclarator" | "Variance" | "VoidPattern" | "VoidTypeAnnotation" | "WhileStatement" | "WithStatement" | "YieldExpression" | "MarkoParseError" | "MarkoDocumentType" | "MarkoDeclaration" | "MarkoCDATA" | "MarkoComment" | "MarkoText" | "MarkoPlaceholder" | "MarkoScriptlet" | "MarkoClass" | "MarkoAttribute" | "MarkoSpreadAttribute" | "MarkoTagBody" | "Standardized" | "Expression" | "Binary" | "Scopable" | "BlockParent" | "Block" | "Statement" | "Terminatorless" | "CompletionStatement" | "Conditional" | "Loop" | "While" | "ExpressionWrapper" | "For" | "ForXStatement" | "FunctionParent" | "Pureish" | "Declaration" | "FunctionParameter" | "PatternLike" | "LVal" | "TSEntityName" | "Literal" | "Immutable" | "UserWhitespacable" | "Method" | "ObjectMember" | "Property" | "UnaryLike" | "Pattern" | "Class" | "ImportOrExportDeclaration" | "ExportDeclaration" | "ModuleSpecifier" | "Accessor" | "Private" | "Flow" | "FlowType" | "FlowBaseAnnotation" | "FlowDeclaration" | "FlowPredicate" | "EnumBody" | "EnumMember" | "JSX" | "Miscellaneous" | "TypeScript" | "TSTypeElement" | "TSType" | "TSBaseType" | "ModuleDeclaration" | "Marko" | "Scope" | "BindingIdentifier" | "BlockScoped" | "ExistentialTypeParam" | "ForAwaitStatement" | "Generated" | "NumericLiteralTypeAnnotation" | "Pure" | "Referenced" | "ReferencedIdentifier" | "ReferencedMemberExpression" | "User" | "Var" | "enter" | "exit" | `${string}|${string}`, t.VisitNode<unknown, t.Node> | undefined>;
6
7
  analyze: Record<"Function" | "MarkoTag" | "AnyTypeAnnotation" | "ArgumentPlaceholder" | "ArrayExpression" | "ArrayPattern" | "ArrayTypeAnnotation" | "ArrowFunctionExpression" | "AssignmentExpression" | "AssignmentPattern" | "AwaitExpression" | "BigIntLiteral" | "BinaryExpression" | "BindExpression" | "BlockStatement" | "BooleanLiteral" | "BooleanLiteralTypeAnnotation" | "BooleanTypeAnnotation" | "BreakStatement" | "CallExpression" | "CatchClause" | "ClassAccessorProperty" | "ClassBody" | "ClassDeclaration" | "ClassExpression" | "ClassImplements" | "ClassMethod" | "ClassPrivateMethod" | "ClassPrivateProperty" | "ClassProperty" | "ConditionalExpression" | "ContinueStatement" | "DebuggerStatement" | "DecimalLiteral" | "DeclareClass" | "DeclareExportAllDeclaration" | "DeclareExportDeclaration" | "DeclareFunction" | "DeclareInterface" | "DeclareModule" | "DeclareModuleExports" | "DeclareOpaqueType" | "DeclareTypeAlias" | "DeclareVariable" | "DeclaredPredicate" | "Decorator" | "Directive" | "DirectiveLiteral" | "DoExpression" | "DoWhileStatement" | "EmptyStatement" | "EmptyTypeAnnotation" | "EnumBooleanBody" | "EnumBooleanMember" | "EnumDeclaration" | "EnumDefaultedMember" | "EnumNumberBody" | "EnumNumberMember" | "EnumStringBody" | "EnumStringMember" | "EnumSymbolBody" | "ExistsTypeAnnotation" | "ExportAllDeclaration" | "ExportDefaultDeclaration" | "ExportDefaultSpecifier" | "ExportNamedDeclaration" | "ExportNamespaceSpecifier" | "ExportSpecifier" | "ExpressionStatement" | "File" | "ForInStatement" | "ForOfStatement" | "ForStatement" | "FunctionDeclaration" | "FunctionExpression" | "FunctionTypeAnnotation" | "FunctionTypeParam" | "GenericTypeAnnotation" | "Identifier" | "IfStatement" | "Import" | "ImportAttribute" | "ImportDeclaration" | "ImportDefaultSpecifier" | "ImportExpression" | "ImportNamespaceSpecifier" | "ImportSpecifier" | "IndexedAccessType" | "InferredPredicate" | "InterfaceDeclaration" | "InterfaceExtends" | "InterfaceTypeAnnotation" | "InterpreterDirective" | "IntersectionTypeAnnotation" | "JSXAttribute" | "JSXClosingElement" | "JSXClosingFragment" | "JSXElement" | "JSXEmptyExpression" | "JSXExpressionContainer" | "JSXFragment" | "JSXIdentifier" | "JSXMemberExpression" | "JSXNamespacedName" | "JSXOpeningElement" | "JSXOpeningFragment" | "JSXSpreadAttribute" | "JSXSpreadChild" | "JSXText" | "LabeledStatement" | "LogicalExpression" | "MemberExpression" | "MetaProperty" | "MixedTypeAnnotation" | "ModuleExpression" | "NewExpression" | "Noop" | "NullLiteral" | "NullLiteralTypeAnnotation" | "NullableTypeAnnotation" | "NumberLiteral" | "NumberLiteralTypeAnnotation" | "NumberTypeAnnotation" | "NumericLiteral" | "ObjectExpression" | "ObjectMethod" | "ObjectPattern" | "ObjectProperty" | "ObjectTypeAnnotation" | "ObjectTypeCallProperty" | "ObjectTypeIndexer" | "ObjectTypeInternalSlot" | "ObjectTypeProperty" | "ObjectTypeSpreadProperty" | "OpaqueType" | "OptionalCallExpression" | "OptionalIndexedAccessType" | "OptionalMemberExpression" | "ParenthesizedExpression" | "PipelineBareFunction" | "PipelinePrimaryTopicReference" | "PipelineTopicExpression" | "Placeholder" | "PrivateName" | "Program" | "QualifiedTypeIdentifier" | "RecordExpression" | "RegExpLiteral" | "RegexLiteral" | "RestElement" | "RestProperty" | "ReturnStatement" | "SequenceExpression" | "SpreadElement" | "SpreadProperty" | "StaticBlock" | "StringLiteral" | "StringLiteralTypeAnnotation" | "StringTypeAnnotation" | "Super" | "SwitchCase" | "SwitchStatement" | "SymbolTypeAnnotation" | "TSAnyKeyword" | "TSArrayType" | "TSAsExpression" | "TSBigIntKeyword" | "TSBooleanKeyword" | "TSCallSignatureDeclaration" | "TSConditionalType" | "TSConstructSignatureDeclaration" | "TSConstructorType" | "TSDeclareFunction" | "TSDeclareMethod" | "TSEnumBody" | "TSEnumDeclaration" | "TSEnumMember" | "TSExportAssignment" | "TSExpressionWithTypeArguments" | "TSExternalModuleReference" | "TSFunctionType" | "TSImportEqualsDeclaration" | "TSImportType" | "TSIndexSignature" | "TSIndexedAccessType" | "TSInferType" | "TSInstantiationExpression" | "TSInterfaceBody" | "TSInterfaceDeclaration" | "TSIntersectionType" | "TSIntrinsicKeyword" | "TSLiteralType" | "TSMappedType" | "TSMethodSignature" | "TSModuleBlock" | "TSModuleDeclaration" | "TSNamedTupleMember" | "TSNamespaceExportDeclaration" | "TSNeverKeyword" | "TSNonNullExpression" | "TSNullKeyword" | "TSNumberKeyword" | "TSObjectKeyword" | "TSOptionalType" | "TSParameterProperty" | "TSParenthesizedType" | "TSPropertySignature" | "TSQualifiedName" | "TSRestType" | "TSSatisfiesExpression" | "TSStringKeyword" | "TSSymbolKeyword" | "TSTemplateLiteralType" | "TSThisType" | "TSTupleType" | "TSTypeAliasDeclaration" | "TSTypeAnnotation" | "TSTypeAssertion" | "TSTypeLiteral" | "TSTypeOperator" | "TSTypeParameter" | "TSTypeParameterDeclaration" | "TSTypeParameterInstantiation" | "TSTypePredicate" | "TSTypeQuery" | "TSTypeReference" | "TSUndefinedKeyword" | "TSUnionType" | "TSUnknownKeyword" | "TSVoidKeyword" | "TaggedTemplateExpression" | "TemplateElement" | "TemplateLiteral" | "ThisExpression" | "ThisTypeAnnotation" | "ThrowStatement" | "TopicReference" | "TryStatement" | "TupleExpression" | "TupleTypeAnnotation" | "TypeAlias" | "TypeAnnotation" | "TypeCastExpression" | "TypeParameter" | "TypeParameterDeclaration" | "TypeParameterInstantiation" | "TypeofTypeAnnotation" | "UnaryExpression" | "UnionTypeAnnotation" | "UpdateExpression" | "V8IntrinsicIdentifier" | "VariableDeclaration" | "VariableDeclarator" | "Variance" | "VoidPattern" | "VoidTypeAnnotation" | "WhileStatement" | "WithStatement" | "YieldExpression" | "MarkoParseError" | "MarkoDocumentType" | "MarkoDeclaration" | "MarkoCDATA" | "MarkoComment" | "MarkoText" | "MarkoPlaceholder" | "MarkoScriptlet" | "MarkoClass" | "MarkoAttribute" | "MarkoSpreadAttribute" | "MarkoTagBody" | "Standardized" | "Expression" | "Binary" | "Scopable" | "BlockParent" | "Block" | "Statement" | "Terminatorless" | "CompletionStatement" | "Conditional" | "Loop" | "While" | "ExpressionWrapper" | "For" | "ForXStatement" | "FunctionParent" | "Pureish" | "Declaration" | "FunctionParameter" | "PatternLike" | "LVal" | "TSEntityName" | "Literal" | "Immutable" | "UserWhitespacable" | "Method" | "ObjectMember" | "Property" | "UnaryLike" | "Pattern" | "Class" | "ImportOrExportDeclaration" | "ExportDeclaration" | "ModuleSpecifier" | "Accessor" | "Private" | "Flow" | "FlowType" | "FlowBaseAnnotation" | "FlowDeclaration" | "FlowPredicate" | "EnumBody" | "EnumMember" | "JSX" | "Miscellaneous" | "TypeScript" | "TSTypeElement" | "TSType" | "TSBaseType" | "ModuleDeclaration" | "Marko" | "Scope" | "BindingIdentifier" | "BlockScoped" | "ExistentialTypeParam" | "ForAwaitStatement" | "Generated" | "NumericLiteralTypeAnnotation" | "Pure" | "Referenced" | "ReferencedIdentifier" | "ReferencedMemberExpression" | "User" | "Var" | "enter" | "exit" | `${string}|${string}`, t.VisitNode<unknown, t.Node> | undefined>;
@@ -1,4 +1,6 @@
1
+ import { types as t } from "@marko/compiler";
1
2
  export declare function isOutputHTML(): boolean;
2
3
  export declare function isOutputDOM(): boolean;
3
4
  export declare function getMarkoOpts(): Required<import("@marko/compiler").Config>;
4
5
  export declare function isOptimize(): boolean;
6
+ export declare function getReadyId(file?: t.BabelFile): string | undefined;
@@ -3,7 +3,6 @@ import { type Many, type Opt, Sorted } from "./optional";
3
3
  import { type Section } from "./sections";
4
4
  import { type SerializeReason } from "./serialize-reasons";
5
5
  import { type Signal } from "./signals";
6
- declare const kIsInvoked: unique symbol;
7
6
  export declare const kBranchSerializeReason: unique symbol;
8
7
  export type Aliases = undefined | Binding | {
9
8
  [property: string]: Aliases;
@@ -39,6 +38,7 @@ export interface Binding {
39
38
  propertyAliases: Map<string, Binding>;
40
39
  excludeProperties: Opt<string>;
41
40
  upstreamAlias: Binding | undefined;
41
+ restOffset: number | undefined;
42
42
  scopeOffset: Binding | undefined;
43
43
  scopeAccessor: string | undefined;
44
44
  export: string | undefined;
@@ -76,8 +76,6 @@ declare module "@marko/compiler/dist/types" {
76
76
  interface NodeExtra {
77
77
  section?: Section;
78
78
  referencedBindings?: ReferencedBindings;
79
- constantBindings?: ReferencedBindings;
80
- hoistedBindings?: ReferencedBindings;
81
79
  downstream?: Opt<Binding>;
82
80
  binding?: Binding;
83
81
  assignment?: Binding;
@@ -87,13 +85,11 @@ declare module "@marko/compiler/dist/types" {
87
85
  isEffect?: true;
88
86
  spreadFrom?: Binding;
89
87
  merged?: NodeExtra;
90
- [kIsInvoked]?: true;
91
88
  }
92
89
  interface FunctionExtra {
93
90
  referencesScope?: boolean;
94
91
  referencedBindingsInFunction?: ReferencedBindings;
95
92
  constantBindingsInFunction?: ReferencedBindings;
96
- hoistedBindingsInFunction?: ReferencedBindings;
97
93
  name?: string;
98
94
  registerId?: string;
99
95
  registerReason?: SerializeReason;
@@ -15,4 +15,5 @@ export declare function getHTMLRuntime(): {
15
15
  _escape_script: typeof _escape_script;
16
16
  _escape_style: typeof _escape_style;
17
17
  };
18
+ export declare function getRuntimePath(output: string): string;
18
19
  export declare function getCompatRuntimeFile(): string;
@@ -1,4 +1,5 @@
1
1
  import { types as t } from "@marko/compiler";
2
+ import type { LoadImportConfig } from "../visitors/import-declaration";
2
3
  declare module "@marko/compiler/dist/types" {
3
4
  interface ProgramExtra {
4
5
  featureType?: "class" | "tags";
@@ -8,6 +9,7 @@ declare module "@marko/compiler/dist/types" {
8
9
  tagNameNullable?: boolean;
9
10
  tagNameDynamic?: boolean;
10
11
  tagNameImported?: string;
12
+ tagNameLoad?: LoadImportConfig;
11
13
  featureType?: ProgramExtra["featureType"];
12
14
  }
13
15
  }
@@ -10,7 +10,7 @@ type VisitCodes = WalkCode.Get | WalkCode.Inside | WalkCode.Replace | WalkCode.D
10
10
  export declare function enter(path: t.NodePath<any>): void;
11
11
  export declare function exit(path: t.NodePath<any>): void;
12
12
  export declare function enterShallow(path: t.NodePath<any>): void;
13
- export declare function injectWalks(tag: t.NodePath<t.MarkoTag>, name: string, expr: Walk): void;
13
+ export declare function injectWalks(tag: t.NodePath<t.MarkoTag>, name: string, expr?: Walk): void;
14
14
  export declare function visit(path: t.NodePath<t.MarkoTag | t.MarkoPlaceholder | t.Program>, code: VisitCodes): void;
15
15
  export declare function getWalkString(section: Section): t.Expression | undefined;
16
16
  export {};
@@ -1,9 +1,18 @@
1
- import type { types as t } from "@marko/compiler";
1
+ import { types as t } from "@marko/compiler";
2
+ import type { LoadTrigger } from "../../html/assets";
2
3
  declare module "@marko/compiler/dist/types" {
3
4
  interface NodeExtra {
4
5
  tagImport?: string;
6
+ loadImport?: LoadImportConfig;
5
7
  }
6
8
  }
9
+ export type LoadImportConfig = {
10
+ render: true;
11
+ triggers?: never;
12
+ } | {
13
+ render: false;
14
+ triggers: LoadTrigger[];
15
+ };
7
16
  declare const _default: {
8
17
  analyze(this: unknown, importDecl: t.NodePath<t.ImportDeclaration>): void;
9
18
  translate: {
@@ -1,4 +1,11 @@
1
1
  import { types as t } from "@marko/compiler";
2
+ import type { Binding } from "../../util/references";
3
+ declare const kLoadTagBinding: unique symbol;
4
+ declare module "@marko/compiler/dist/types" {
5
+ interface MarkoTagExtra {
6
+ [kLoadTagBinding]?: Binding;
7
+ }
8
+ }
2
9
  declare const _default: {
3
10
  analyze: {
4
11
  enter(this: unknown, tag: t.NodePath<t.MarkoTag>): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "marko",
3
- "version": "6.1.2",
3
+ "version": "6.1.4",
4
4
  "description": "Optimized runtime for Marko templates.",
5
5
  "keywords": [
6
6
  "api",
@@ -49,7 +49,7 @@
49
49
  "build": "node -r ~ts ./scripts/bundle.mts"
50
50
  },
51
51
  "dependencies": {
52
- "@marko/compiler": "^5.39.62",
52
+ "@marko/compiler": "^5.39.64",
53
53
  "csstype": "^3.2.3",
54
54
  "fastest-levenshtein": "^1.0.16",
55
55
  "magic-string": "^0.30.21"