Home / Class/ $state Class — svelte Architecture

$state Class — svelte Architecture

Architecture documentation for the $state class in index.d.ts from the svelte codebase.

Entity Profile

Dependency Diagram

graph TD
  5de96491_2169_82a2_83ab_9c007adb020f["$state"]
  6bd9d090_a582_e05c_669e_d53d4e7245f2["index.d.ts"]
  5de96491_2169_82a2_83ab_9c007adb020f -->|defined in| 6bd9d090_a582_e05c_669e_d53d4e7245f2
  c9b1b826_d301_a3d6_8c53_c09b5a96af24["$state()"]
  5de96491_2169_82a2_83ab_9c007adb020f -->|method| c9b1b826_d301_a3d6_8c53_c09b5a96af24
  180e3470_49a6_8cb5_d88a_fd1983ec38de["toJSON()"]
  5de96491_2169_82a2_83ab_9c007adb020f -->|method| 180e3470_49a6_8cb5_d88a_fd1983ec38de
  107c660b_6b04_e53b_164d_eff75ff0eada["eager()"]
  5de96491_2169_82a2_83ab_9c007adb020f -->|method| 107c660b_6b04_e53b_164d_eff75ff0eada
  a1701e85_6818_4951_80a2_f5aec5dd5bd8["raw()"]
  5de96491_2169_82a2_83ab_9c007adb020f -->|method| a1701e85_6818_4951_80a2_f5aec5dd5bd8
  533460a2_a00a_cb90_83c1_578c962db541["snapshot()"]
  5de96491_2169_82a2_83ab_9c007adb020f -->|method| 533460a2_a00a_cb90_83c1_578c962db541

Relationship Graph

Source Code

packages/svelte/types/index.d.ts lines 3195–3195

declare function $state<T>(initial: T): T;

Frequently Asked Questions

What is the $state class?
$state is a class in the svelte codebase, defined in packages/svelte/types/index.d.ts.
Where is $state defined?
$state is defined in packages/svelte/types/index.d.ts at line 3195.

Analyze Your Own Codebase

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

Try Supermodel Free