Socket
Socket
Sign inDemoInstall

os-browserify

Package Overview
Dependencies
0
Maintainers
2
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    os-browserify

The [os](https://nodejs.org/api/os.html) module from node.js, but for browsers.


Version published
Weekly downloads
8.5M
increased by3.16%
Maintainers
2
Install size
3.71 kB
Created
Weekly downloads
 

Package description

What is os-browserify?

The os-browserify npm package is a browser shim for Node.js's OS module, allowing for certain operating system-related utilities to be used in browser environments. This package provides a subset of the Node.js OS module's functionality that makes sense in a browser context, such as getting the current platform.

What are os-browserify's main functionalities?

Platform

This feature allows you to get the platform the code is running on. In the context of os-browserify, it always returns 'browser' since the code is expected to run in a browser environment.

"use strict";\nvar os = require('os-browserify');\nconsole.log(os.platform()); // 'browser'"

EOL

This feature provides the end-of-line marker for the current environment. In a browser context, this is typically '\n', similar to Unix/Linux systems.

"use strict";\nvar os = require('os-browserify');\nconsole.log(os.EOL); // '\n'"

Other packages similar to os-browserify

Readme

Source

os-browserify

The os module from node.js, but for browsers.

When you require('os') in browserify, this module will be loaded.

FAQs

Last updated on 20 Apr 2017

Did you know?

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc