DebugTag() — svelte Function Reference
Architecture documentation for the DebugTag() function in DebugTag.js from the svelte codebase.
Entity Profile
Dependency Diagram
graph TD ab54a4f6_348b_e6a1_12df_f251caab3980["DebugTag()"] 99f4258f_995e_45a4_cd10_76de9e869540["DebugTag.js"] ab54a4f6_348b_e6a1_12df_f251caab3980 -->|defined in| 99f4258f_995e_45a4_cd10_76de9e869540 style ab54a4f6_348b_e6a1_12df_f251caab3980 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/svelte/src/compiler/phases/3-transform/client/visitors/DebugTag.js lines 10–28
export function DebugTag(node, context) {
const object = b.object(
node.identifiers.map((identifier) => {
const visited = b.call('$.snapshot', /** @type {Expression} */ (context.visit(identifier)));
return b.prop(
'init',
identifier,
context.state.analysis.runes ? visited : b.call('$.untrack', b.thunk(visited))
);
})
);
const call = b.call('console.log', object);
context.state.init.push(
b.stmt(b.call('$.template_effect', b.thunk(b.block([b.stmt(call), b.debugger]))))
);
}
Domain
Subdomains
Source
Frequently Asked Questions
What does DebugTag() do?
DebugTag() is a function in the svelte codebase, defined in packages/svelte/src/compiler/phases/3-transform/client/visitors/DebugTag.js.
Where is DebugTag() defined?
DebugTag() is defined in packages/svelte/src/compiler/phases/3-transform/client/visitors/DebugTag.js at line 10.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free