wrangler-action/node_modules/std-env
2023-08-07 15:11:15 -05:00
..
dist Temp fix for deps issue 2023-08-07 15:11:15 -05:00
LICENCE Temp fix for deps issue 2023-08-07 15:11:15 -05:00
package.json Temp fix for deps issue 2023-08-07 15:11:15 -05:00
README.md Temp fix for deps issue 2023-08-07 15:11:15 -05:00

std-env

npm npm bundlephobia

Detect current Javascript environment

Installation

# Using Yarn
yarn add std-env

# Using npm
npm i std-env

Usage

// ESM
import { isWindows } from 'std-env'

// CommonJS
const { isCI } = require('std-env')

Available exports:

  • hasTTY
  • hasWindow
  • isCI
  • isDebug
  • isDevelopment
  • isLinux
  • isMacOS
  • isMinimal
  • isProduction
  • isTest
  • isWindows
  • platform
  • provider

You can read more about how each flag works from ./src/index.ts.

List of well known providers can be found from ./src/providers.ts.

License

MIT