Skip to main content
Module

x/deno2node/src/deps.deno.ts>JSDoc

Compile your Deno project to run on Node.js.
Go to Latest
class JSDoc
extends JSDocBase<ts.JSDoc>
import { JSDoc } from "https://deno.land/x/deno2node@v1.7.1/src/deps.deno.ts";

JS doc node.

Methods

addTag(structure: OptionalKind<JSDocTagStructure>): JSDocTag<ts.JSDocTag>

Adds a JS doc tag.

addTags(structures: ReadonlyArray<OptionalKind<JSDocTagStructure>>): JSDocTag<ts.JSDocTag>[]

Adds JS doc tags.

getComment(): string | ()[] | undefined

Gets the comment property. Use #getCommentText() to get the text of the JS doc comment if necessary.

getCommentText(): string | undefined

Gets the text of the JS doc comment.

getDescription(): string

Gets the description from the JS doc comment.

getInnerText(): string

Gets the JSDoc's text without the surrounding slashes and stars.

getParentOrThrow(message?: string | (() => string)): NonNullable<NodeParentType<ts.JSDoc>>

Gets the structure equivalent to this node.

Gets the tags of the JSDoc.

insertTag(index: number, structure: OptionalKind<JSDocTagStructure>): JSDocTag<ts.JSDocTag>

Inserts a JS doc tag at the specified index.

insertTags(index: number, structures: ReadonlyArray<OptionalKind<JSDocTagStructure>>): JSDocTag<ts.JSDocTag>[]

Inserts JS doc tags at the specified index.

isMultiLine(): boolean

Gets if this JS doc spans multiple lines.

remove(): void

Removes this JSDoc.

set(structure: Partial<JSDocStructure>): Node<ts.Node>

Sets the node from a structure.

setDescription(textOrWriterFunction: string | WriterFunction): this

Sets the description.