Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface UserAgentParser

UserAgentParser is responsible to parse the browser's user agent and provide the parsed result.

Hierarchy

  • UserAgentParser

Implemented by

Index

Methods

getParserResult

  • getParserResult(): {}

Optional updateWithHighEntropyValues

  • updateWithHighEntropyValues(alwaysOverride: boolean): Promise<void>
  • Updates internal values using the User-Agent Client Hints API. If the API is not available, resolves without making changes.

    Parameters

    • alwaysOverride: boolean

      If true, always override internal values even if already set. Examples of value changes:

      • osName: "Mac OS" → "macOS"
      • osVersion: "10.15" → "10.15.7"
      • browserName: "Chrome" → "Google Chrome"
      • browserVersion: "120" → "120.0.6099.129"

    Returns Promise<void>

    Promise that resolves when update is complete

Generated using TypeDoc