mirror of
https://github.com/faisalman/ua-parser-js.git
synced 2025-09-27 07:58:45 +03:00
Fix d.ts Record for extensions as Partial
This commit is contained in:
parent
e4f2463849
commit
3622b614a7
2
src/main/ua-parser.d.ts
vendored
2
src/main/ua-parser.d.ts
vendored
@ -48,7 +48,7 @@ declare namespace UAParser {
|
|||||||
|
|
||||||
type RegexMap = ((RegExp | string | (string | RegExp | Function)[])[])[];
|
type RegexMap = ((RegExp | string | (string | RegExp | Function)[])[])[];
|
||||||
type UAParserProps = 'browser' | 'cpu' | 'device' | 'engine' | 'os';
|
type UAParserProps = 'browser' | 'cpu' | 'device' | 'engine' | 'os';
|
||||||
type UAParserExt = Record<UAParserProps, RegexMap>;
|
type UAParserExt = Partial<Record<UAParserProps, RegexMap>>;
|
||||||
|
|
||||||
export function UAParser(uastring?: string, extensions?: UAParserExt, headers?: Record<string, string>): IResult;
|
export function UAParser(uastring?: string, extensions?: UAParserExt, headers?: Record<string, string>): IResult;
|
||||||
export function UAParser(uastring?: string, headers?: Record<string, string>): IResult;
|
export function UAParser(uastring?: string, headers?: Record<string, string>): IResult;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user