diff --git a/docs/Bowser.html b/docs/Bowser.html index 14d2e60..02daa42 100644 --- a/docs/Bowser.html +++ b/docs/Bowser.html @@ -27,7 +27,7 @@
@@ -492,7 +492,7 @@ explicitly. Same as skipParsing for Parser diff --git a/docs/Parser.html b/docs/Parser.html index 7273dc3..3f4865b 100644 --- a/docs/Parser.html +++ b/docs/Parser.html @@ -27,7 +27,7 @@
@@ -1712,7 +1712,7 @@ like Parser#parseBrowser or Source:
@@ -2004,11 +2004,6 @@ the OS called "anything" or the platform called "anything" - -string - - - @@ -2083,468 +2078,6 @@ the OS called "anything" or the platform called "anything"Returns: - - - - -
-
- Type -
-
- -boolean - - -
-
- - - - - - - - - - -

isEngine(engineName) → {boolean}

- - - - - - -
- - -
Source:
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - -
-

Check if the engine name equals the passed string

-
- - - - - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
engineName - - -string - - - -

The string to compare with the engine name

- - - - - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - -
-
- - - - - - - - - - -

isOS(osName) → {boolean}

- - - - - - -
- - -
Source:
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - -
-

Check if the OS name equals the passed string

-
- - - - - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
osName - - -string - - - -

The string to compare with the OS name

- - - - - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - -
-
- - - - - - - - - - -

isPlatform(platformType) → {boolean}

- - - - - - -
- - -
Source:
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - -
-

Check if the platform type equals the passed string

-
- - - - - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
platformType - - -string - - - -

The string to compare with the platform type

- - - - - - - - - - - - - - - -
Returns:
@@ -3285,7 +2818,7 @@ Returns undefined when the browser is no described in the checkTree
Source:
@@ -3596,7 +3129,7 @@ Returns undefined when the browser is no described in the checkTree
- Documentation generated by JSDoc 3.6.3 on Sat Aug 09 2025 17:59:04 GMT+0000 (Coordinated Universal Time) using the docdash theme. + Documentation generated by JSDoc 3.6.3 on Sat Sep 12 2020 11:21:13 GMT+0300 (Eastern European Summer Time) using the docdash theme.
diff --git a/docs/bowser.js.html b/docs/bowser.js.html index f2bdc3a..c33671e 100644 --- a/docs/bowser.js.html +++ b/docs/bowser.js.html @@ -27,7 +27,7 @@
@@ -133,7 +133,7 @@ export default Bowser;
- Documentation generated by JSDoc 3.6.3 on Sat Aug 09 2025 17:59:04 GMT+0000 (Coordinated Universal Time) using the docdash theme. + Documentation generated by JSDoc 3.6.3 on Sat Sep 12 2020 11:21:13 GMT+0300 (Eastern European Summer Time) using the docdash theme.
diff --git a/docs/global.html b/docs/global.html index 5d541ff..5d7a1c7 100644 --- a/docs/global.html +++ b/docs/global.html @@ -27,7 +27,7 @@
@@ -867,7 +867,7 @@
-

Get browser name for a short version/alias

+

Get short version/alias for a browser name

@@ -880,7 +880,7 @@
Example
-
getBrowserTypeByAlias('edge') // Microsoft Edge
+
getBrowserAlias('edge') // Microsoft Edge
@@ -2706,7 +2706,7 @@ like "iPhone" or "Kindle Fire HD 7"
- Documentation generated by JSDoc 3.6.3 on Sat Aug 09 2025 17:59:04 GMT+0000 (Coordinated Universal Time) using the docdash theme. + Documentation generated by JSDoc 3.6.3 on Sat Sep 12 2020 11:21:13 GMT+0300 (Eastern European Summer Time) using the docdash theme.
diff --git a/docs/index.html b/docs/index.html index 5dc820b..f9cb242 100644 --- a/docs/index.html +++ b/docs/index.html @@ -27,7 +27,7 @@
@@ -70,11 +70,13 @@

Overview

The library is made to help to detect what browser your user has and gives you a convenient API to filter the users somehow depending on their browsers. Check it out on this page: https://bowser-js.github.io/bowser-online/.

⚠️ Version 2.0 breaking changes ⚠️

-

Version 2.0 has drastically changed the API. All available methods are on the docs page.

+

Version 2.0 has drastically changed the API. All available methods are on the docs page.

For legacy code, check out the 1.x branch and install it through npm install bowser@1.9.4.

Use cases

First of all, require the library. This is a UMD Module, so it will work for AMD, TypeScript, ES6, and CommonJS module systems.

@@ -174,7 +176,7 @@ list of aliases can be found in the file.

Contributors

Code Contributors

-

This project exists thanks to all the people who contribute. [Contribute]. +

This project exists thanks to all the people who contribute. [Contribute].

Financial Contributors

Become a financial contributor and help us sustain our community. [Contribute]

@@ -208,7 +210,7 @@ list of aliases can be found in the file.


- Documentation generated by JSDoc 3.6.3 on Sat Aug 09 2025 17:59:04 GMT+0000 (Coordinated Universal Time) using the docdash theme. + Documentation generated by JSDoc 3.6.3 on Sat Sep 12 2020 11:21:13 GMT+0300 (Eastern European Summer Time) using the docdash theme.
diff --git a/docs/parser.js.html b/docs/parser.js.html index 0b176ed..11adc02 100644 --- a/docs/parser.js.html +++ b/docs/parser.js.html @@ -27,7 +27,7 @@
@@ -131,7 +131,7 @@ class Parser { return _browser.test(this); } - if (Array.isArray(_browser.test)) { + if (_browser.test instanceof Array) { return _browser.test.some(condition => this.test(condition)); } @@ -214,7 +214,7 @@ class Parser { return _os.test(this); } - if (Array.isArray(_os.test)) { + if (_os.test instanceof Array) { return _os.test.some(condition => this.test(condition)); } @@ -290,7 +290,7 @@ class Parser { return _platform.test(this); } - if (Array.isArray(_platform.test)) { + if (_platform.test instanceof Array) { return _platform.test.some(condition => this.test(condition)); } @@ -341,7 +341,7 @@ class Parser { return _engine.test(this); } - if (Array.isArray(_engine.test)) { + if (_engine.test instanceof Array) { return _engine.test.some(condition => this.test(condition)); } @@ -452,7 +452,7 @@ class Parser { /** * Check if the browser name equals the passed string - * @param {string} browserName The string to compare with the browser name + * @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} */ @@ -503,29 +503,14 @@ class Parser { ) > -1; } - /** - * Check if the OS name equals the passed string - * @param {string} osName The string to compare with the OS name - * @returns {boolean} - */ isOS(osName) { return this.getOSName(true) === String(osName).toLowerCase(); } - /** - * Check if the platform type equals the passed string - * @param {string} platformType The string to compare with the platform type - * @returns {boolean} - */ isPlatform(platformType) { return this.getPlatformType(true) === String(platformType).toLowerCase(); } - /** - * Check if the engine name equals the passed string - * @param {string} engineName The string to compare with the engine name - * @returns {boolean} - */ isEngine(engineName) { return this.getEngineName(true) === String(engineName).toLowerCase(); } @@ -567,7 +552,7 @@ export default Parser;
- Documentation generated by JSDoc 3.6.3 on Sat Aug 09 2025 17:59:04 GMT+0000 (Coordinated Universal Time) using the docdash theme. + Documentation generated by JSDoc 3.6.3 on Sat Sep 12 2020 11:21:13 GMT+0300 (Eastern European Summer Time) using the docdash theme.
diff --git a/docs/utils.js.html b/docs/utils.js.html index 03eec59..b20a008 100644 --- a/docs/utils.js.html +++ b/docs/utils.js.html @@ -27,7 +27,7 @@
@@ -339,10 +339,10 @@ export default class Utils { } /** - * Get browser name for a short version/alias + * Get short version/alias for a browser name * * @example - * getBrowserTypeByAlias('edge') // Microsoft Edge + * getBrowserAlias('edge') // Microsoft Edge * * @param {string} browserAlias * @return {string} @@ -365,7 +365,7 @@ export default class Utils {
- Documentation generated by JSDoc 3.6.3 on Sat Aug 09 2025 17:59:04 GMT+0000 (Coordinated Universal Time) using the docdash theme. + Documentation generated by JSDoc 3.6.3 on Sat Sep 12 2020 11:21:13 GMT+0300 (Eastern European Summer Time) using the docdash theme.