Home / File/ fragment.js — svelte Source File

fragment.js — svelte Source File

Architecture documentation for fragment.js, a javascript file in the svelte codebase. 0 imports, 24 dependents.

File javascript Compiler Transformer 24 dependents 1 functions

Entity Profile

Dependency Diagram

graph LR
  c4b4ac8d_9914_5ede_1aea_723bf80d2e9b["fragment.js"]
  4aa8a188_84d4_0274_ed83_cac0ab1d3572["index.js"]
  4aa8a188_84d4_0274_ed83_cac0ab1d3572 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  d8d7142f_9b03_9f6b_6c45_52a298690d08["AttachTag.js"]
  d8d7142f_9b03_9f6b_6c45_52a298690d08 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  28ec60f4_a82f_1f06_ded7_1786b05aa1c0["Attribute.js"]
  28ec60f4_a82f_1f06_ded7_1786b05aa1c0 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  93e88a6f_3f11_4770_b83f_853f9bf1fc2b["AwaitBlock.js"]
  93e88a6f_3f11_4770_b83f_853f9bf1fc2b --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  6b8c189e_23e1_77d3_9ee3_3eec5012a9b2["BindDirective.js"]
  6b8c189e_23e1_77d3_9ee3_3eec5012a9b2 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  a4b067ca_8345_0d46_f70d_05c6255f3ba3["ClassDirective.js"]
  a4b067ca_8345_0d46_f70d_05c6255f3ba3 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  7cf83ecb_26f4_e326_a28c_a905bbed7141["EachBlock.js"]
  7cf83ecb_26f4_e326_a28c_a905bbed7141 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  563e8414_1dd4_f5bf_e346_91afa5cea4b9["ExpressionTag.js"]
  563e8414_1dd4_f5bf_e346_91afa5cea4b9 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  93b0ec70_ae65_2771_721b_d69136053c03["HtmlTag.js"]
  93b0ec70_ae65_2771_721b_d69136053c03 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  dbcd64ee_7333_aa92_9b8e_ed189c6c4449["Identifier.js"]
  dbcd64ee_7333_aa92_9b8e_ed189c6c4449 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  349b9b06_99f6_79ed_a469_c74ec514305c["IfBlock.js"]
  349b9b06_99f6_79ed_a469_c74ec514305c --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  32ff766e_8f23_837c_5646_c073d4b6ae96["KeyBlock.js"]
  32ff766e_8f23_837c_5646_c073d4b6ae96 --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  50cc33f3_339a_55a6_7256_b481927bcf1a["OnDirective.js"]
  50cc33f3_339a_55a6_7256_b481927bcf1a --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  60af7ccf_2ceb_e5af_2432_c5b753a12c2a["RegularElement.js"]
  60af7ccf_2ceb_e5af_2432_c5b753a12c2a --> c4b4ac8d_9914_5ede_1aea_723bf80d2e9b
  style c4b4ac8d_9914_5ede_1aea_723bf80d2e9b fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

/** @import { AST } from '#compiler' */

/**
 * @param {AST.SvelteNode[]} path
 */
export function mark_subtree_dynamic(path) {
	let i = path.length;
	while (i--) {
		const node = path[i];
		if (node.type === 'Fragment') {
			if (node.metadata.dynamic) return;
			node.metadata.dynamic = true;
		}
	}
}

Domain

Subdomains

Imported By

Frequently Asked Questions

What does fragment.js do?
fragment.js is a source file in the svelte codebase, written in javascript. It belongs to the Compiler domain, Transformer subdomain.
What functions are defined in fragment.js?
fragment.js defines 1 function(s): mark_subtree_dynamic.
What files import fragment.js?
fragment.js is imported by 24 file(s): AttachTag.js, Attribute.js, AwaitBlock.js, BindDirective.js, ClassDirective.js, EachBlock.js, ExpressionTag.js, HtmlTag.js, and 16 more.
Where is fragment.js in the architecture?
fragment.js is located at packages/svelte/src/compiler/phases/2-analyze/visitors/shared/fragment.js (domain: Compiler, subdomain: Transformer, directory: packages/svelte/src/compiler/phases/2-analyze/visitors/shared).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free