Home / Function/ to_processed() — svelte Function Reference

to_processed() — svelte Function Reference

Architecture documentation for the to_processed() function in index.js from the svelte codebase.

Function javascript Compiler Migrator calls 1 called by 1

Entity Profile

Dependency Diagram

graph TD
  d378c79f_a5b8_3e96_866c_2dfa63c43532["to_processed()"]
  9ef48db2_c88d_10c7_b63f_fd4636d6af64["PreprocessResult"]
  d378c79f_a5b8_3e96_866c_2dfa63c43532 -->|defined in| 9ef48db2_c88d_10c7_b63f_fd4636d6af64
  a7a70deb_64ca_bb14_028e_9cb3aec87b0f["preprocess()"]
  a7a70deb_64ca_bb14_028e_9cb3aec87b0f -->|calls| d378c79f_a5b8_3e96_866c_2dfa63c43532
  c005db55_c14e_aa09_dbae_d0b302ec93df["combine_sourcemaps()"]
  d378c79f_a5b8_3e96_866c_2dfa63c43532 -->|calls| c005db55_c14e_aa09_dbae_d0b302ec93df
  style d378c79f_a5b8_3e96_866c_2dfa63c43532 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/svelte/src/compiler/preprocess/index.js lines 83–98

	to_processed() {
		// Combine all the source maps for each preprocessor function into one
		// @ts-expect-error TODO there might be a bug in hiding here
		const map = combine_sourcemaps(this.file_basename, this.sourcemap_list);
		return {
			// TODO return separated output, in future version where svelte.compile supports it:
			// style: { code: styleCode, map: styleMap },
			// script { code: scriptCode, map: scriptMap },
			// markup { code: markupCode, map: markupMap },
			code: this.source,
			dependencies: [...new Set(this.dependencies)],
			// @ts-expect-error TODO there might be a bug in hiding here
			map,
			toString: () => this.source
		};
	}

Domain

Subdomains

Called By

Frequently Asked Questions

What does to_processed() do?
to_processed() is a function in the svelte codebase, defined in packages/svelte/src/compiler/preprocess/index.js.
Where is to_processed() defined?
to_processed() is defined in packages/svelte/src/compiler/preprocess/index.js at line 83.
What does to_processed() call?
to_processed() calls 1 function(s): combine_sourcemaps.
What calls to_processed()?
to_processed() is called by 1 function(s): preprocess.

Analyze Your Own Codebase

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

Try Supermodel Free