Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

browser-info

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

browser-info - npm Package Compare versions

Comparing version 0.0.4 to 0.1.0

5

index.js

@@ -22,5 +22,8 @@ /* globals navigator*/

}
if (ua.indexOf('Linux' )!== -1) {
if (ua.indexOf('Linux' ) !== -1) {
os = 'Linux';
}
if (ua.indexOf('Android') !== -1) {
os = 'Android';
}

@@ -27,0 +30,0 @@ if (/trident/i.test(match[1])) {

2

package.json
{
"name": "browser-info",
"version": "0.0.4",
"version": "0.1.0",
"description": "Get browser info",

@@ -5,0 +5,0 @@ "author": "Steve Lacy <me@slacy.me> (http://slacy.me)",

@@ -19,2 +19,10 @@ 'use strict';

it('should detect Android', function(done) {
GLOBAL.navigator = {
userAgent: 'Mozilla/5.0 (Linux; Android 5.0; SM-G900P Build/LRX21T) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.23 Mobile Safari/537.36'
};
should(info().os).equal('Android');
done();
});
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc