Socket
Socket
Sign inDemoInstall

spdx-correct

Package Overview
Dependencies
1
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    spdx-correct

correct invalid SPDX identifiers


Version published
Maintainers
1
Install size
54.9 kB
Created

Package description

What is spdx-correct?

The spdx-correct npm package is used to correct invalid SPDX license identifiers to valid ones. SPDX (Software Package Data Exchange) is a standard format for communicating the licensing information of software packages. The spdx-correct package takes a possibly incorrect SPDX expression and returns a corrected version that is valid according to the SPDX specification, if possible.

What are spdx-correct's main functionalities?

Correcting invalid SPDX license identifiers

This feature takes an invalid SPDX license identifier, such as 'Apache 2.0', and corrects it to a valid identifier, 'Apache-2.0'.

"use strict";
const spdxCorrect = require('spdx-correct');
const corrected = spdxCorrect('Apache 2.0');
console.log(corrected); // 'Apache-2.0'

Other packages similar to spdx-correct

Readme

Source

spdx-correct.js

npm version license build status

Correct invalid SPDX identifiers.

correct('mit'); // => 'MIT'

correct('Apache 2'); // => 'Apache-2.0'

correct('No idea what license'); // => null

Keywords

FAQs

Last updated on 03 May 2015

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