import { type ModifierableNode } from "https://deno.land/x/ts_morph@16.0.0/mod.ts";
Methods
getModifiers(): Node<ts.Modifier>[]
Gets the node's modifiers.
getFirstModifierByKindOrThrow<TKind extends SyntaxKind>(kind: TKind): KindToNodeMappings[TKind]
Gets the first modifier of the specified syntax kind or throws if none found.
getFirstModifierByKind<TKind extends SyntaxKind>(kind: TKind): KindToNodeMappings[TKind] | undefined
Gets the first modifier of the specified syntax kind or undefined if none found.
hasModifier(kind: SyntaxKind): boolean
Gets if it has the specified modifier.
hasModifier(text: ModifierTexts): boolean
Gets if it has the specified modifier.
toggleModifier(text: ModifierTexts, value?: boolean): this
Toggles a modifier.
import { ModifierableNode } from "https://deno.land/x/ts_morph@16.0.0/mod.ts";
Type Parameters
T extends Constructor<ModifierableNodeExtensionType>
Parameters
Base: T