EsLintIssuesAliases.

EsLintAddRuleUrlResolver(ICakeContext, Func<BaseRuleDescription, Uri>) Method

Summary

Registers a new URL resolver with default priority of 0.

Syntax

public static void EsLintAddRuleUrlResolver(this ICakeContext context, Func<BaseRuleDescription, Uri> resolver)

Examples

Adds a provider with default priority of 0 returning a link for all rules starting with the string Foo to search with Google for the rule:

EsLintAddRuleUrlResolver(x =>
    x.Rule.StartsWith("Foo") ?
    new Uri("https://www.google.com/search?q=%22" + x.Rule + "%22") :
    null)

Attributes

Type Description
CakeMethodAliasAttribute
CakeAliasCategoryAttribute

Parameters

Name Type Description
context ICakeContext The context.
resolver Func<BaseRuleDescription, Uri> Resolver which returns an System.Uri linking to a site containing help for a specific BaseRuleDescription.

Return Value

Type Description
void