detect-browser
Advanced tools
Comparing version 1.8.0 to 1.9.0
@@ -8,2 +8,3 @@ module.exports = function detectBrowser(userAgentString) { | ||
[ 'vivaldi', /Vivaldi\/([0-9\.]+)/ ], | ||
[ 'kakaotalk', /KAKAOTALK\s([0-9\.]+)/ ], | ||
[ 'chrome', /(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/ ], | ||
@@ -10,0 +11,0 @@ [ 'crios', /CriOS\/([0-9\.]+)(:?\s|$)/ ], |
{ | ||
"name": "detect-browser", | ||
"version": "1.8.0", | ||
"version": "1.9.0", | ||
"description": "Unpack a browser type and version from the useragent string", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -175,2 +175,16 @@ var test = require('tape'); | ||
test('detects Kakaotalk Browser', function(t) { | ||
assertAgentString(t, | ||
'Netscape 5.0 (iPhone; CPU iPhone OS 10_3 1 like Mac OS X) AppleWebKit/603.1.30 (KHTML, like Gecko) Mobile/14E304 KAKAOTALK 6.2.2', | ||
{ name: 'kakaotalk', version: '6.2.2' } | ||
); | ||
assertAgentString(t, | ||
'Mozilla/5.0 (iPhone; CPU iPhone OS 10_3 1 like Mac OS X) AppleWebKit/ 603.1.30 (KHTML, like Gecko) Mobile/ 14E304 KAKAOTALK 6.2.2', | ||
{ name: 'kakaotalk', version: '6.2.2' } | ||
); | ||
t.end(); | ||
}); | ||
test('handles no browser', function(t) { | ||
@@ -177,0 +191,0 @@ assertAgentString(t, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15885
264