Home / Function/ branch() — svelte Function Reference

branch() — svelte Function Reference

Architecture documentation for the branch() function in effects.js from the svelte codebase.

Entity Profile

Dependency Diagram

graph TD
  4ca1b5f2_087e_afec_72d9_534a30fbfe1f["branch()"]
  1ae6fa4e_16ee_acdf_5e28_17eb0819fddb["effects.js"]
  4ca1b5f2_087e_afec_72d9_534a30fbfe1f -->|defined in| 1ae6fa4e_16ee_acdf_5e28_17eb0819fddb
  3d4087a1_f844_f105_4e79_f5f1a65e1203["hmr()"]
  3d4087a1_f844_f105_4e79_f5f1a65e1203 -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  faf0e92f_7626_2d66_f7f8_05458f022351["branch()"]
  faf0e92f_7626_2d66_f7f8_05458f022351 -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  8783b6d3_ff2d_7032_cf54_f6a71da85e37["ensure()"]
  8783b6d3_ff2d_7032_cf54_f6a71da85e37 -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  7f76e82e_4ed8_1525_9136_2ae67868d44e["each()"]
  7f76e82e_4ed8_1525_9136_2ae67868d44e -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  a433c00f_4d97_9041_6d87_ef0086b2aea7["create_item()"]
  a433c00f_4d97_9041_6d87_ef0086b2aea7 -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  4133c9ed_6ce6_0847_e62e_62aaf8690ab4["attach()"]
  4133c9ed_6ce6_0847_e62e_62aaf8690ab4 -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  9a87a496_4e7d_9214_8bba_7bb2e3e47939["attribute_effect()"]
  9a87a496_4e7d_9214_8bba_7bb2e3e47939 -->|calls| 4ca1b5f2_087e_afec_72d9_534a30fbfe1f
  9764bb93_860c_6dee_2112_890b69ee0aa3["create_effect()"]
  4ca1b5f2_087e_afec_72d9_534a30fbfe1f -->|calls| 9764bb93_860c_6dee_2112_890b69ee0aa3
  style 4ca1b5f2_087e_afec_72d9_534a30fbfe1f fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/svelte/src/internal/client/reactivity/effects.js lines 418–420

export function branch(fn) {
	return create_effect(BRANCH_EFFECT | EFFECT_PRESERVED, fn, true);
}

Domain

Subdomains

Frequently Asked Questions

What does branch() do?
branch() is a function in the svelte codebase, defined in packages/svelte/src/internal/client/reactivity/effects.js.
Where is branch() defined?
branch() is defined in packages/svelte/src/internal/client/reactivity/effects.js at line 418.
What does branch() call?
branch() calls 1 function(s): create_effect.
What calls branch()?
branch() is called by 7 function(s): attach, attribute_effect, branch, create_item, each, ensure, hmr.

Analyze Your Own Codebase

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

Try Supermodel Free