findUseTypeshadeDirective
On this page

findUseTypeshadeDirective()

Function in Authoring

Scan the top-level statements of a SourceFile and return the first "use typeshade"; directive, or undefined if none is present.

import { findUseTypeshadeDirective } from 'typeshade'

The signature, the description and the examples come from the compiler's own source at commit 26de7be8.

Syntax

function findUseTypeshadeDirective(
sourceFile: ts.SourceFile,
): ts.ExpressionStatement | undefined

Parameters

sourceFile ts.SourceFile

Return value

ts.ExpressionStatement | undefined

Description

Only direct children of the SourceFile are examined (no nested scopes).

Source

src/compiler/ts/directive.ts, line 41, at commit 26de7be8

Edit this page Report a problem