- Preparing search index...
- The search index is not available
Markuplit API
- mlRuleTest<T, O>(rule: Readonly<RuleSeed<T, O>>, sourceCode: string, config?: Omit<Config, "rules" | "childNodeRules" | "nodeRules"> & {
childNodeRule?: ChildNodeRule<T, Partial<O>>[];
nodeRule?: NodeRule<T, Partial<O>>[];
rule?: Rule<T, Partial<O>>;
}, fix?: boolean, locale?: string): Promise<{
fixedCode: string;
violations: readonly Violation[];
}>
-
Parameters
-
rule: Readonly<RuleSeed<T, O>>
-
sourceCode: string
-
config: Omit<Config, "rules" | "childNodeRules" | "nodeRules"> & {
childNodeRule?: ChildNodeRule<T, Partial<O>>[];
nodeRule?: NodeRule<T, Partial<O>>[];
rule?: Rule<T, Partial<O>>;
} = ...
-
fix: boolean = false
-
locale: string = 'en'
Returns Promise<{
fixedCode: string;
violations: readonly Violation[];
}>