is-env
is-env
is a current detector.
Can check the js
operating environment is browser
or react-native
or nodejs
or weapp
.
In addition to browser
, nodejs
, react-native
, weapp
, other output unknow
.
Only ie9+ and modern browsers are supported in browsers.
install
npm install --save is-env
use
const isEnv = ; ;;;;
When the parameter is a non string, output the current environment.
const isEnv = ;