Skip to content
This repository has been archived by the owner on Apr 16, 2020. It is now read-only.

ipfs-inactive/browser-process-platform

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This repository has been archived!

This IPFS-related repository has been archived, and all issues are therefore frozen. If you want to ask a question or open/continue a discussion related to this repo, please visit the official IPFS forums.

We archive repos for one or more of the following reasons:

  • Code or content is unmaintained, and therefore might be broken
  • Content is outdated, and therefore may mislead readers
  • Code or content evolved into something else and/or has lived on in a different place
  • The repository or project is not active in general

Please note that in order to keep the primary IPFS GitHub org tidy, most archived repos are moved into the ipfs-inactive org.

If you feel this repo should not be archived (or portions of it should be moved to a non-archived repo), please reach out and let us know. Archiving can always be reversed if needed.


browser-process-platform

Browser shim for Node.js process.platform.

See documentation at nodejs.org.

Background

When running tests in Node.js as well as in the Browser, you might want to skip tests depending on the platform. With this shim it is possible to use process.platform independent of the environment.

I’d like to thank @kumavis for his browser-process-hrtime module, it was a great inspiration to create this module.

Install

> npm install browser-process-platform

Usage

Via monkey-patching

process.platform = require('browser-process-platform')
console.log('The current platform is:', process.platform)

As module

const platform = require('browser-process-platform')
console.log('The current platform is:', platform)

Maintainers

@vmx

Contribute

Feel free to join in. All welcome. Open an issue!

This repository falls under the IPFS Code of Conduct and follows the IPFS guidelines for JavaScript projects.

Small note: If editing the README, please conform to the standard-readme specification.

License

MIT © 2018 Protocol Labs, Inc.

About

[ARCHIVED] Browser shim for Node.js process.platform.

Resources

License

Stars

Watchers

Forks

Packages

No packages published