getDirectiveScriptText() — astro Function Reference
Architecture documentation for the getDirectiveScriptText() function in scripts.ts from the astro codebase.
Entity Profile
Dependency Diagram
graph TD 5bd1f38e_d9ec_d821_510e_5b00dc744d01["getDirectiveScriptText()"] 7d939579_ff24_6e88_6d95_2d48a8dbe011["scripts.ts"] 5bd1f38e_d9ec_d821_510e_5b00dc744d01 -->|defined in| 7d939579_ff24_6e88_6d95_2d48a8dbe011 cf35fbda_f098_09ca_b464_4ea610fb0825["getPrescripts()"] cf35fbda_f098_09ca_b464_4ea610fb0825 -->|calls| 5bd1f38e_d9ec_d821_510e_5b00dc744d01 style 5bd1f38e_d9ec_d821_510e_5b00dc744d01 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/astro/src/runtime/server/scripts.ts lines 23–30
function getDirectiveScriptText(result: SSRResult, directive: string): string {
const clientDirectives = result.clientDirectives;
const clientDirective = clientDirectives.get(directive);
if (!clientDirective) {
throw new Error(`Unknown directive: ${directive}`);
}
return clientDirective;
}
Domain
Subdomains
Defined In
Called By
Source
Frequently Asked Questions
What does getDirectiveScriptText() do?
getDirectiveScriptText() is a function in the astro codebase, defined in packages/astro/src/runtime/server/scripts.ts.
Where is getDirectiveScriptText() defined?
getDirectiveScriptText() is defined in packages/astro/src/runtime/server/scripts.ts at line 23.
What calls getDirectiveScriptText()?
getDirectiveScriptText() is called by 1 function(s): getPrescripts.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free