types (EN) - bhsd-harry/wikiparser-node GitHub Wiki
Expand
AST in JSON format.
property: range start and end indices
type: [number, number]
property: type token type, unavailable for text nodes
type: string | undefined
property: name token name if available
type: string | undefined
property: childNodes array of child nodes, unavailable for text nodes
type: AST[] | undefined
property: data data of text nodes
type: string | undefined
✅ Expand
Parse configuration.
property: ext extension tags
type: string[]
property: html HTML tags
type: [string[], string[], string[]]
property: namespaces namespaces
type: Record<string, string>
property: nsid namespace IDs
type: Record<string, number>
property: variable variables
type: string[]
property: functionHook parser functions
type: string[]
property: parserFunction variables or parser functions
type: [Record<string, string>, Record<string, string>, string[], string[]]
property: doubleUnderscore behavior switches
type: [string[], string[], Record<string, string>?, Record<string, string>?]
property: protocol external link protocol
type: string
property: interwiki interwiki prefixes
type: string[]
property: img image parameters
type: Record<string, string>
property: redirection magic words for redirection
type: string[]
property: variants language variants
type: string[]
property: articlePath $wgArticlePath, optional
type: string
property: conversionTable unidirectional conversion table, optional
type: [string, string][]
property: redirects redirects, optional
type: [string, string][]
Expand
version added: 1.22.0
A basic JSON frame object for the #invoke parser function.
property: args arguments passed to the frame
type: Record<string, string>
property: parent the parent frame, if any
type: Frame | undefined
property: title the title of the module
type: string
Expand
version added: 1.25.1
A JSON object for configuring the linter.
property: rules rule configuration
type: Record<LintError.Rule, unknown>
property: computeEditInfo whether to compute quick fixes or suggestions for individual issues, default to true
type: boolean
property: fix whether to compute fix-all suggestions for the entire document, default to true
type: boolean
property: ignoreDisables whether to ignore inline configuration comments, default to false
type: boolean
✅ Expand
Grammar error.
property: rule rule name
type: LintError.Rule
property: message error type
type: string
property: severity error severity
type: 'error' | 'warning'
property: startIndex start position
type: number
property: endIndex end position
type: number
property: startLine start line
type: number
property: endLine end line
type: number
property: startCol start column
type: number
property: endCol end column
type: number
property: fix auto-fix, optional
type: LintError.Fix
property: suggestions suggestions, optional
type: LintError.Fix[]
✅ Expand
Fix suggestion for grammar error.
property: range start and end positions
type: [number, number]
property: text replacement text
type: string
property: desc description
type: string