Socket
Book a DemoInstallSign in
Socket

mutants-env

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mutants-env

用友容器 环境检测

latest
npmnpm
Version
2.0.9
Version published
Weekly downloads
13
550%
Maintainers
1
Weekly downloads
 
Created
Source

mutants-env

模块说明

使用ts编写的环境检测库,他可以动态检测出容器环境,平台,操作系统,浏览器版本等信息

检测依据

通过user-agent进行操作系统,平台,浏览器等环境检测

OS

  • Mobile
  • Ios
  • Android
  • Computer

浏览器

  • Internet_explorer
  • Chrome
  • Firefox
  • Safari
  • Opera
  • Unknown

容器

  • Weixin: 微信容器 | 关键字: micromessenger
  • Chanjet: 工作圈容器 | 关键字: chanjet
  • Electron: Electron客户端 | 关键字: electron
  • Yonyou: 友空间容器 | 关键字: qyzone

使用说明

import env from 'mutants-env';
const {platform,constant} = env;
if(constant.platform.Yonyou === platform){
  //执行友空间容器内的逻辑
}

Keywords

user-agent

FAQs

Package last updated on 01 Feb 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts