1
0
mirror of https://github.com/lancedikson/bowser synced 2024-10-27 20:34:22 +00:00

Merge branch 'master' into greenkeeper/monorepo.babel7-20200114033043

This commit is contained in:
Denis Demchenko 2020-01-28 21:53:59 +02:00 committed by GitHub
commit 433955ac68
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 695 additions and 1044 deletions

18
index.d.ts vendored
View File

@ -22,6 +22,14 @@ declare namespace Bowser {
function parse(UA: string): Parser.ParsedResult;
/**
* Constants exposed via bowser getters
*/
const BROWSER_MAP: Record<string, string>;
const ENGINE_MAP: Record<string, string>;
const OS_MAP: Record<string, string>;
const PLATFORMS_MAP: Record<string, string>;
namespace Parser {
interface Parser {
constructor(UA: string, skipParsing?: boolean): Parser.Parser;
@ -174,6 +182,16 @@ declare namespace Bowser {
satisfies(checkTree: checkTree): boolean | undefined;
/**
* Check if the browser name equals the passed string
* @param browserName The string to compare with the browser name
* @param [includingAlias=false] The flag showing whether alias will be included into comparison
* @returns {boolean}
*/
isBrowser(browserName: string, includingAlias?: boolean): boolean;
/**
* Check if any of the given values satifies `.is(anything)`
* @param {string[]} anythings

1717
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -34,7 +34,7 @@
"@babel/polyfill": "^7.8.3",
"@babel/preset-env": "^7.8.2",
"@babel/register": "^7.8.3",
"ava": "^2.4.0",
"ava": "^3.0.0",
"babel-eslint": "^10.0.3",
"babel-loader": "^8.0.6",
"babel-plugin-add-module-exports": "^1.0.2",
@ -44,7 +44,7 @@
"docdash": "^1.1.1",
"eslint": "^6.5.1",
"eslint-config-airbnb-base": "^13.2.0",
"eslint-plugin-ava": "^8.0.0",
"eslint-plugin-ava": "^10.0.0",
"eslint-plugin-import": "^2.18.2",
"gh-pages": "^2.1.1",
"jsdoc": "^3.6.3",