版博士V2.0程序
Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. # std-env
  2. [![npm](https://img.shields.io/npm/dm/std-env.svg?style=flat-square)](http://npmjs.com/package/std-env)
  3. [![npm](https://img.shields.io/npm/v/std-env.svg?style=flat-square)](http://npmjs.com/package/std-env)
  4. [![bundlephobia](https://img.shields.io/bundlephobia/min/std-env/latest.svg?style=flat-square)](https://bundlephobia.com/result?p=std-env)
  5. > Detect current Javascript environment
  6. ## Installation
  7. ```sh
  8. # Using Yarn
  9. yarn add std-env
  10. # Using npm
  11. npm i std-env
  12. ```
  13. ## Usage
  14. ```js
  15. // ESM
  16. import { isWindows } from 'std-env'
  17. // CommonJS
  18. const { isCI } = require('std-env')
  19. ```
  20. Available exports:
  21. - `hasTTY`
  22. - `hasWindow`
  23. - `isCI`
  24. - `isDebug`
  25. - `isDevelopment`
  26. - `isLinux`
  27. - `isMacOS`
  28. - `isMinimal`
  29. - `isProduction`
  30. - `isTest`
  31. - `isWindows`
  32. - `platform`
  33. - `provider`
  34. You can read more about how each flag works from [./src/index.ts](./src/index.ts).
  35. List of well known providers can be found from [./src/providers.ts](./src/providers.ts).
  36. ## License
  37. MIT