Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SuggestBestMatch

Suggest the best match for the provided URL fragment if no exact match has been found

Hierarchy

  • SuggestBestMatch

Index

Constructors

constructor

  • new SuggestBestMatch(urlFragment: string, arrayToSearch: Array<string>): SuggestBestMatch

Properties

Private arrayToSearch

arrayToSearch: Array<string>

the full list of the URLs of the website gotten from the sitemap.

Private bestMatch

bestMatch: BestMatch

The best match for the URL fragment provided as found by method findBestMatch of string-similarity.

Private bestUrl

bestUrl: string

Best match in form of absolute URL from the target value.

Private finalText

finalText: string

The tip text to display in console.

Private urlFragment

urlFragment: string

the URL fragment provided in the directive.

Methods

Private buildFinalText

  • buildFinalText(): void

find

  • find(): string

Private findBestMatch

  • findBestMatch(): void

Private pathToUrl

  • pathToUrl(): void