Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

global-prefix

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

global-prefix

Get the npm global path prefix.

  • 0.1.4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
6.9M
decreased by-58.56%
Maintainers
1
Weekly downloads
 
Created

What is global-prefix?

The global-prefix npm package provides a way to determine the path of the global npm directory on a system. This can be useful for packages that need to know where global modules are installed, for example, to check if a certain global package is installed or to install a package globally programmatically.

What are global-prefix's main functionalities?

Get global npm prefix

This feature allows you to retrieve the path of the global npm directory. The code sample requires the global-prefix module and then logs the global npm prefix to the console.

const globalPrefix = require('global-prefix');
console.log(globalPrefix);

Other packages similar to global-prefix

Keywords

FAQs

Package last updated on 05 Jun 2016

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc