Socket
Socket
Sign inDemoInstall

spdx-license-ids

Package Overview
Dependencies
0
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

spdx-license-ids

A list of SPDX license identifiers


Version published
Maintainers
1
Weekly downloads
25,440,431
decreased by-6.75%

Weekly downloads

Package description

What is spdx-license-ids?

The spdx-license-ids package provides a list of SPDX license identifiers. SPDX (Software Package Data Exchange) is a standard format for communicating the licensing information of software packages. This package is useful for validating license identifiers, checking if a license ID is deprecated, and listing all valid SPDX license IDs.

What are spdx-license-ids's main functionalities?

List of all SPDX license IDs

This feature provides an array of all non-deprecated SPDX license identifiers. You can use this list to validate or display available licenses.

const spdxLicenseIds = require('spdx-license-ids');
console.log(spdxLicenseIds);

List of deprecated SPDX license IDs

This feature provides an array of deprecated SPDX license identifiers. It is useful for checking if a license ID is no longer valid according to the SPDX specification.

const spdxLicenseIdsDeprecated = require('spdx-license-ids/deprecated');
console.log(spdxLicenseIdsDeprecated);

Other packages similar to spdx-license-ids

Readme

Source

spdx-license-ids

npm version Github Actions

A list of SPDX license identifiers

Installation

Download JSON directly, or use npm:

npm install spdx-license-ids

Node.js API

require('spdx-license-ids')

Type: string[]

All license IDs except for the currently deprecated ones.

const ids = require('spdx-license-ids');
//=> ['0BSD', 'AAL', 'ADSL', 'AFL-1.1', 'AFL-1.2', 'AFL-2.0', 'AFL-2.1', 'AFL-3.0', 'AGPL-1.0-only', ...]

ids.includes('BSD-3-Clause'); //=> true
ids.includes('CC-BY-1.0'); //=> true

ids.includes('GPL-3.0'); //=> false

require('spdx-license-ids/deprecated')

Type: string[]

Deprecated license IDs.

const deprecatedIds = require('spdx-license-ids/deprecated');
//=> ['AGPL-1.0', 'AGPL-3.0', 'GFDL-1.1', 'GFDL-1.2', 'GFDL-1.3', 'GPL-1.0', 'GPL-2.0', ...]

deprecatedIds.includes('BSD-3-Clause'); //=> false
deprecatedIds.includes('CC-BY-1.0'); //=> false

deprecatedIds.includes('GPL-3.0'); //=> true

License

Creative Commons Zero v1.0 Universal

Keywords

FAQs

Last updated on 11 Jul 2019

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