Home / Function/ get_or_init_context_map() — svelte Function Reference

get_or_init_context_map() — svelte Function Reference

Architecture documentation for the get_or_init_context_map() function in context.js from the svelte codebase.

Entity Profile

Dependency Diagram

graph TD
  02617af0_3f57_bf68_b817_c98e6360c268["get_or_init_context_map()"]
  54c11eb3_9f61_b300_a3b1_1e9710d714ea["context.js"]
  02617af0_3f57_bf68_b817_c98e6360c268 -->|defined in| 54c11eb3_9f61_b300_a3b1_1e9710d714ea
  d855a5d9_17d5_6a25_ee1f_64ac528d61b5["getContext()"]
  d855a5d9_17d5_6a25_ee1f_64ac528d61b5 -->|calls| 02617af0_3f57_bf68_b817_c98e6360c268
  0a45d259_64d5_75b4_ce4d_ebf63caaaa4c["setContext()"]
  0a45d259_64d5_75b4_ce4d_ebf63caaaa4c -->|calls| 02617af0_3f57_bf68_b817_c98e6360c268
  41c62d3e_96b1_f956_ed71_f29f6d5f06f6["hasContext()"]
  41c62d3e_96b1_f956_ed71_f29f6d5f06f6 -->|calls| 02617af0_3f57_bf68_b817_c98e6360c268
  a72fe8a7_1b4c_494f_dece_00bf09ebd656["getAllContexts()"]
  a72fe8a7_1b4c_494f_dece_00bf09ebd656 -->|calls| 02617af0_3f57_bf68_b817_c98e6360c268
  250aa633_f9f1_0e83_0cb1_5cde0e6c74c6["get_parent_context()"]
  02617af0_3f57_bf68_b817_c98e6360c268 -->|calls| 250aa633_f9f1_0e83_0cb1_5cde0e6c74c6
  style 02617af0_3f57_bf68_b817_c98e6360c268 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/svelte/src/internal/server/context.js lines 73–79

function get_or_init_context_map(name) {
	if (ssr_context === null) {
		e.lifecycle_outside_component(name);
	}

	return (ssr_context.c ??= new Map(get_parent_context(ssr_context) || undefined));
}

Domain

Subdomains

Frequently Asked Questions

What does get_or_init_context_map() do?
get_or_init_context_map() is a function in the svelte codebase, defined in packages/svelte/src/internal/server/context.js.
Where is get_or_init_context_map() defined?
get_or_init_context_map() is defined in packages/svelte/src/internal/server/context.js at line 73.
What does get_or_init_context_map() call?
get_or_init_context_map() calls 1 function(s): get_parent_context.
What calls get_or_init_context_map()?
get_or_init_context_map() is called by 4 function(s): getAllContexts, getContext, hasContext, setContext.

Analyze Your Own Codebase

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

Try Supermodel Free