1
0
mirror of https://github.com/lancedikson/bowser synced 2026-09-23 12:34:58 +00:00

Add Electron

This commit is contained in:
Farfurix
2019-12-04 15:55:36 +03:00
parent d95fe87b06
commit 648daa5f9f
3 changed files with 73 additions and 0 deletions

View File

@@ -531,6 +531,21 @@ const browsersList = [
return browser;
},
},
{
test: [/electron/i],
describe(ua) {
const browser = {
name: 'Electron',
};
const version = Utils.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i, ua);
if (version) {
browser.version = version;
}
return browser;
},
},
{
test: [/chromium/i],
describe(ua) {