Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Generated on May 15, 2024 via pnpm

globals 13.24.0

Global identifiers from different JavaScript environments
Package summary
Share
0
issues
2
licenses
1
MIT
1
(MIT OR CC0-1.0)
Package created
3 Nov 2012
Version published
10 Dec 2023
Maintainers
4
Total deps
2
Direct deps
1
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
globals@13.24.0

(MIT OR CC0-1.0)

Public Domain
1 Packages, Including:
type-fest@0.20.2
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

1
All Dependencies CSV
β“˜ This is a list of globals 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
type-fest0.20.236.35 kB(MIT OR CC0-1.0)
prod

Visualizations

Frequently Asked Questions

What does globals do?

Globals is a compelling JavaScript package that provides an array of global identifiers from various JavaScript environments. The primary function of Globals is to serve as a comprehensive JSON file which can be utilized in any environment. Notably, it is widely employed by ESLint, a popular static code analysis tool, to flag any deviations in variable behavior based on their "read-only" or "overwritable" status. The Globals package is particularly renowned for its extensive inclusion of both Node.js built-in global identifiers and CommonJS arguments, enhancing its functionality and versatility.

How do you use globals?

The 'globals' package is conveniently user-friendly and can be installed and used seamlessly. To kickstart the process, you need to install the package using npm with the command npm install globals. Post-installation, you can require 'globals' and utilize it in your JavaScript code. For instance,

const globals = require('globals');
console.log(globals.browser);

This code snippet will log an object containing browser-specific global identifiers from the 'globals' package. The boolean values associated with each global, indicating whether a global identifier is "read-only" (false) or "overwritable" (true), serve as flags for static analysis tools to check for any incorrect behaviors.

Where are the globals docs?

The comprehensive documentation for the 'globals' package can be accessed directly from the package's JSON file, found here. This JSON file contains a rich and useful collection of global identifiers from different JavaScript environments. More specific documentation, for instance, on the globals available on different platforms like Node.js or browser, can also be fetched from their respective official websites. Links to these resources are embedded in the provided JSON file.