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

user-device-type

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

user-device-type - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

LICENSE

7

dist/my-lib.es.js

@@ -1,6 +0,7 @@

function t(e) {
return "desktop";
function a(e) {
const t = /Mobile|Android|iP(hone|od)|BlackBerry|IEMobile|Silk|Opera Mini|Fennec|webOS|Windows Phone|PlayStation Vita/i, o = /Tablet|iPad|Nexus 7|Nexus 9|Kindle|Silk|Fennec/i, i = /Win(dows NT|dows NT 10.0|dows NT 6.1|dows NT 6.2|dows NT 6.3|dows NT 5.1|dows NT 5.2|dows NT 6.0|dows NT 5.0)|Macintosh|Intel Mac OS X|Linux|Ubuntu|CrOS/i, n = /SmartTV|AppleTV|GoogleTV|HbbTV|NetCast|WebTV|Tizen|Roku|Xbox|PlayStation|CrKey|DIAL/i;
return /Watch|Wearable|Google Glass|SmartWatch|Gear/i.test(e) ? "wearable" : n.test(e) ? "tv" : o.test(e) ? "tablet" : t.test(e) ? "mobile" : i.test(e) ? "desktop" : "unknown";
}
export {
t as getDeviceType
a as getDeviceType
};

@@ -1,1 +0,1 @@

(function(e,t){typeof exports=="object"&&typeof module<"u"?t(exports):typeof define=="function"&&define.amd?define(["exports"],t):(e=typeof globalThis<"u"?globalThis:e||self,t(e["device-type"]={}))})(this,function(e){"use strict";function t(n){return"desktop"}e.getDeviceType=t,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});
(function(e,t){typeof exports=="object"&&typeof module<"u"?t(exports):typeof define=="function"&&define.amd?define(["exports"],t):(e=typeof globalThis<"u"?globalThis:e||self,t(e["device-type"]={}))})(this,function(e){"use strict";function t(o){const i=/Mobile|Android|iP(hone|od)|BlackBerry|IEMobile|Silk|Opera Mini|Fennec|webOS|Windows Phone|PlayStation Vita/i,n=/Tablet|iPad|Nexus 7|Nexus 9|Kindle|Silk|Fennec/i,s=/Win(dows NT|dows NT 10.0|dows NT 6.1|dows NT 6.2|dows NT 6.3|dows NT 5.1|dows NT 5.2|dows NT 6.0|dows NT 5.0)|Macintosh|Intel Mac OS X|Linux|Ubuntu|CrOS/i,l=/SmartTV|AppleTV|GoogleTV|HbbTV|NetCast|WebTV|Tizen|Roku|Xbox|PlayStation|CrKey|DIAL/i;return/Watch|Wearable|Google Glass|SmartWatch|Gear/i.test(o)?"wearable":l.test(o)?"tv":n.test(o)?"tablet":i.test(o)?"mobile":s.test(o)?"desktop":"unknown"}e.getDeviceType=t,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});

@@ -17,7 +17,8 @@ {

},
"version": "0.0.1",
"version": "0.0.2",
"scripts": {
"dev": "vite",
"build": "vite build",
"preview": "vite preview"
"preview": "vite preview",
"build-docs": "vite build --config vite.config.client.js"
},

@@ -24,0 +25,0 @@ "devDependencies": {

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