Gathering detailed insights and metrics for spdx
Gathering detailed insights and metrics for spdx
Gathering detailed insights and metrics for spdx
Gathering detailed insights and metrics for spdx
npm install spdx
Typescript
Module System
Node Version
NPM Version
98.9
Supply Chain
99.6
Quality
77.7
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
12,288,148
Last Day
2,305
Last Week
40,906
Last Month
165,654
Last Year
1,936,611
MIT License
53 Stars
81 Commits
9 Forks
7 Watchers
6 Branches
3 Contributors
Updated on Dec 28, 2024
Minified
Minified + Gzipped
Latest Version
0.5.2
Package Id
spdx@0.5.2
Size
12.22 kB
NPM Version
6.3.0
Node Version
8.11.1
Published on
Aug 06, 2018
Cumulative downloads
Total Downloads
Last Day
17.1%
2,305
Compared to previous day
Last Week
9.9%
40,906
Compared to previous week
Last Month
-3.2%
165,654
Compared to previous month
Last Year
60.7%
1,936,611
Compared to previous year
2
3
Development on spdx.js has moved to separate, smaller packages.
spdx-expression-parse and spdx-satisfies are direct successors to spdx.js.
You may also be interested in spdx-compare, spdx-correct, and other packages on the npm public registry. kemitchell writes a lot of them.
1var spdx = require('spdx')
1var assert = require('assert') 2assert(spdx.valid('Invalid-Identifier') === null) 3assert(spdx.valid('GPL-2.0')) 4assert(spdx.valid('GPL-2.0+')) 5assert(spdx.valid('LicenseRef-23')) 6assert(spdx.valid('LicenseRef-MIT-Style-1')) 7assert(spdx.valid('DocumentRef-spdx-tool-1.2:LicenseRef-MIT-Style-2'))
OR
Operator1assert(spdx.valid('(LGPL-2.1 OR MIT)')) 2assert(spdx.valid('(LGPL-2.1 OR MIT OR BSD-3-Clause)'))
AND
Operator1assert(spdx.valid('(LGPL-2.1 AND MIT)')) 2assert(spdx.valid('(LGPL-2.1 AND MIT AND BSD-2-Clause)'))
WITH
Operator1assert(spdx.valid('(GPL-2.0+ WITH Bison-exception-2.2)'))
1assert.deepEqual( 2 spdx.parse('(LGPL-2.1 OR BSD-3-Clause AND MIT)'), 3 { left: { license: 'LGPL-2.1' }, 4 conjunction: 'or', 5 right: { 6 left: { license: 'BSD-3-Clause' }, 7 conjunction: 'and', 8 right: { license: 'MIT' } } }) 9 10assert.deepEqual( 11 spdx.parse('(MIT AND (LGPL-2.1+ AND BSD-3-Clause))'), 12 { left: { license: 'MIT' }, 13 conjunction: 'and', 14 right: { 15 left: { 16 license: 'LGPL-2.1', 17 plus: true }, 18 conjunction: 'and', 19 right: { license: 'BSD-3-Clause' } } })
1assert(!spdx.valid('MIT ')) 2assert(!spdx.valid(' MIT')) 3assert(!spdx.valid('MIT AND BSD-3-Clause'))
1assert(Array.isArray(spdx.licenses)) 2assert(spdx.licenses.indexOf('ISC') > -1) 3assert(spdx.licenses.indexOf('Apache-1.7') < 0) 4assert(spdx.licenses.every(function(element) { 5 return typeof element === 'string' })) 6 7assert(Array.isArray(spdx.exceptions)) 8assert(spdx.exceptions.indexOf('GCC-exception-3.1') > -1) 9assert(spdx.exceptions.every(function(element) { 10 return typeof element === 'string' }))
1assert.equal(spdx.specificationVersion, '2.0')
The Software Package Data Exchange (SPDX) specification is the work of the Linux Foundation and its contributors, and is licensed under the terms of the Creative Commons Attribution License 3.0 Unported (SPDX: "CC-BY-3.0"). "SPDX" is a United States federally registered trademark of the Linux Foundation.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
Found 1/29 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-04-21
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More