Skip to content

loadRule

Moe Myat Zaw edited this page Jun 7, 2019 · 1 revision

The loadRule method is used to load and cache rule by name early. If the rule already in cache and 'refresh' is false, then returns the cached rule.

Signature

loadRule(
    ruleName: string, 
    refresh: boolean = false): Observable<TranslitRule | TranslitRuleParsed>

Parameters

  • ruleName - The rule name to load and cache rule.
  • refresh - Flag to force reload rule.

Returns

Returns the Observable<TranslitRule | TranslitRuleParsed> object.