{"_id":"spdx-vir","_rev":"4-7fe8d149949182eae9472164a9f88423","name":"spdx-vir","dist-tags":{"latest":"1.0.0"},"versions":{"0.0.0":{"name":"spdx-vir","version":"0.0.0","keywords":[],"author":"","license":"MIT","_id":"spdx-vir@0.0.0","maintainers":[{"name":"electrovir","email":"pithy.gut0a@icloud.com"}],"dist":{"shasum":"72c667c9b732ac150934366b5bb1b8c705e3858d","tarball":"https://registry.npmjs.org/spdx-vir/-/spdx-vir-0.0.0.tgz","fileCount":1,"integrity":"sha512-fO9h4Cjd4iDpZrwxlB7CUkxvmDqnUqTFSkujG9BmunHSKmUO/9CGHDeD0/NiUWPyqoMolRLqqWJucU7OWCDY/g==","signatures":[{"sig":"MEQCIDp+hPv1Iq5QGiwqWEMFOMwOpUYB0ZMV4uv8GQ9CmaIzAiBD+XTvkL/mQBjKdnQ6T5fFX7HUGy0GcwbE1P6KVSO1+Q==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":244},"main":"index.js","type":"commonjs","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"electrovir","email":"pithy.gut0a@icloud.com"},"_npmVersion":"11.15.0","description":"","directories":{},"_nodeVersion":"22.22.3","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/spdx-vir_0.0.0_1780578232335_0.055997973070924356","host":"s3://npm-registry-packages-npm-production"}},"0.0.1":{"name":"spdx-vir","version":"0.0.1","keywords":["SPDX","parse"],"author":{"url":"https://github.com/electrovir","name":"electrovir"},"license":"(MIT OR CC0-1.0)","_id":"spdx-vir@0.0.1","maintainers":[{"name":"electrovir","email":"pithy.gut0a@icloud.com"}],"homepage":"https://github.com/electrovir/spdx-vir","bugs":{"url":"https://github.com/electrovir/spdx-vir/issues"},"dist":{"shasum":"780b999c4a3501952ac32daa79562f23c736a43b","tarball":"https://registry.npmjs.org/spdx-vir/-/spdx-vir-0.0.1.tgz","fileCount":18,"integrity":"sha512-ohpu0LB574zcoBi/R0nArab8YZaux315RRjJF3pUbW5zXnj5DWJ3Tc33zMZCcwQoVmMWGJxRQURVWFywUB5Ryg==","signatures":[{"sig":"MEYCIQCt2nFm285t4sWCkAw80U9FeCLN5Ih5JJrZRvY5OPAq0gIhAK1HJnIcZiCgHR/pRsmM/okywFNHbM3Sz0NKacfK3Pg2","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":453216},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","module":"dist/index.js","engines":{"node":">=22"},"gitHead":"e35f07ac9f09cc641874e4bce31a6ac0bfe0592a","scripts":{"docs":"virmator docs","lint":"virmator lint fix","test":"virmator test web","format":"virmator format","compile":"virmator compile","publish":"virmator publish npm run test:all","test:all":"npm run compile && runstorm --names tests,spelling,format,docs,deps,lint \"npm run test:coverage\" \"npm run test:spelling\" \"npm run test:format\" \"npm run test:docs\" \"npm run test:deps\" \"npm run test:lint\"","test:deps":"virmator deps check","test:docs":"virmator docs check","test:lint":"virmator lint","test:format":"virmator format check","test:coverage":"npm run test coverage","test:spelling":"virmator spellcheck"},"_npmUser":{"name":"electrovir","email":"pithy.gut0a@icloud.com"},"repository":{"url":"git+https://github.com/electrovir/spdx-vir.git","type":"git"},"_npmVersion":"11.15.0","description":"Easy SPDX parsing.","directories":{},"sideEffects":false,"_nodeVersion":"22.22.3","dependencies":{"@augment-vir/common":"^31.71.3"},"_hasShrinkwrap":false,"devDependencies":{"cspell":"^10.0.0","eslint":"^9.39.2","esbuild":"^0.28.0","typedoc":"^0.28.19","prettier":"3.3.3","virmator":"^14.19.1","@eslint/js":"9.39.2","typescript":"^5.9.3","@eslint/eslintrc":"^3.3.5","@web/test-runner":"^0.20.2","@augment-vir/test":"^31.71.3","npm-check-updates":"^22.2.1","typescript-eslint":"8.57.1","dependency-cruiser":"^17.4.3","@augment-vir/assert":"^31.71.3","eslint-plugin-jsdoc":"^63.0.0","prettier-plugin-toml":"^2.0.6","eslint-plugin-sonarjs":"^4.0.3","eslint-plugin-unicorn":"^64.0.0","prettier-plugin-jsdoc":"^1.8.1","eslint-config-prettier":"^10.1.8","eslint-plugin-prettier":"^5.5.6","@web/dev-server-esbuild":"^1.0.5","@stylistic/eslint-plugin":"^5.10.0","eslint-plugin-playwright":"^2.10.4","prettier-plugin-sort-json":"^4.2.0","eslint-plugin-monorepo-cop":"^1.0.2","@stylistic/eslint-plugin-ts":"^4.4.1","@web/test-runner-playwright":"^0.11.1","prettier-plugin-packagejson":"^3.0.2","istanbul-smart-text-reporter":"^1.1.5","markdown-code-example-inserter":"^3.0.5","@typescript-eslint/eslint-plugin":"^8.60.0","eslint-plugin-require-extensions":"^0.1.3","prettier-plugin-multiline-arrays":"~4.1.8","prettier-plugin-organize-imports":"^4.3.0","prettier-plugin-interpolated-html-tags":"^2.0.1"},"_npmOperationalInternal":{"tmp":"tmp/spdx-vir_0.0.1_1780584132620_0.10196777432107584","host":"s3://npm-registry-packages-npm-production"}},"0.0.2":{"name":"spdx-vir","version":"0.0.2","keywords":["SPDX","parse"],"author":{"url":"https://github.com/electrovir","name":"electrovir"},"license":"(MIT OR CC0-1.0)","_id":"spdx-vir@0.0.2","maintainers":[{"name":"electrovir","email":"pithy.gut0a@icloud.com"}],"homepage":"https://github.com/electrovir/spdx-vir","bugs":{"url":"https://github.com/electrovir/spdx-vir/issues"},"dist":{"shasum":"232f90bf0a1924abfb5763bf06ce5baef72ab7aa","tarball":"https://registry.npmjs.org/spdx-vir/-/spdx-vir-0.0.2.tgz","fileCount":18,"integrity":"sha512-7UdQOdgU2HueaK2hBU2zZv3HkP9dh0Fr+RynsUEpc0anQzpWjNjBE7+slsqcpbz2sYkjti3bmR6OFz3XFEmQBg==","signatures":[{"sig":"MEQCIBFXpxoaeuNYQpSRQgEOutUkgpuGHXYwvLayid50+3xVAiB8utpsghn1OBkf8Tz0yAH1nOduaxNq3OI6IDyhytkbmw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":453213},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","module":"dist/index.js","engines":{"node":">=22"},"gitHead":"2c22ffe9ccda45e10288c0bc30262c030de7e596","scripts":{"docs":"virmator docs","lint":"virmator lint fix","test":"virmator test web","format":"virmator format","compile":"virmator compile","publish":"virmator publish npm run test:all","test:all":"npm run compile && runstorm --names tests,spelling,format,docs,deps,lint \"npm run test:coverage\" \"npm run test:spelling\" \"npm run test:format\" \"npm run test:docs\" \"npm run test:deps\" \"npm run test:lint\"","test:deps":"virmator deps check","test:docs":"virmator docs check","test:lint":"virmator lint","test:format":"virmator format check","test:coverage":"npm run test coverage","test:spelling":"virmator spellcheck"},"_npmUser":{"name":"electrovir","email":"pithy.gut0a@icloud.com"},"repository":{"url":"git+https://github.com/electrovir/spdx-vir.git","type":"git"},"_npmVersion":"11.17.0","description":"Easy SPDX parsing.","directories":{},"sideEffects":false,"_nodeVersion":"22.22.3","dependencies":{"@augment-vir/common":"^32.1.0"},"_hasShrinkwrap":false,"devDependencies":{"cspell":"^10.0.1","eslint":"^10.6.0","esbuild":"^0.28.1","typedoc":"^0.28.20","prettier":"3.3.3","virmator":"^14.28.1","@eslint/js":"10.0.1","typescript":"^6.0.3","@eslint/eslintrc":"^3.3.5","@web/test-runner":"^1.0.0","@augment-vir/test":"^32.1.0","npm-check-updates":"^22.2.9","typescript-eslint":"8.63.0","dependency-cruiser":"^18.0.0","@augment-vir/assert":"^32.1.0","eslint-plugin-jsdoc":"^63.0.12","prettier-plugin-toml":"^2.0.6","eslint-plugin-sonarjs":"^4.1.0","eslint-plugin-unicorn":"^71.1.0","prettier-plugin-jsdoc":"^1.8.1","eslint-config-prettier":"^10.1.8","eslint-plugin-prettier":"^5.5.6","@web/dev-server-esbuild":"^2.0.0","@stylistic/eslint-plugin":"^5.10.0","eslint-plugin-playwright":"^2.10.5","prettier-plugin-sort-json":"^4.2.0","eslint-plugin-monorepo-cop":"^1.0.2","@stylistic/eslint-plugin-ts":"^4.4.1","@web/test-runner-playwright":"^1.0.0","prettier-plugin-packagejson":"^3.0.2","istanbul-smart-text-reporter":"^1.1.5","markdown-code-example-inserter":"^3.0.6","@typescript-eslint/eslint-plugin":"^8.63.0","eslint-plugin-require-extensions":"^0.1.3","prettier-plugin-multiline-arrays":"~4.1.10","prettier-plugin-organize-imports":"^4.3.0","prettier-plugin-interpolated-html-tags":"^2.0.1"},"_npmOperationalInternal":{"tmp":"tmp/spdx-vir_0.0.2_1783955721593_0.2469335053952293","host":"s3://npm-registry-packages-npm-production"}},"1.0.0":{"name":"spdx-vir","version":"1.0.0","description":"Easy SPDX parsing.","keywords":["SPDX","parse"],"homepage":"https://github.com/electrovir/spdx-vir","bugs":{"url":"https://github.com/electrovir/spdx-vir/issues"},"repository":{"type":"git","url":"git+https://github.com/electrovir/spdx-vir.git"},"license":"(MIT OR CC0-1.0)","author":{"name":"electrovir","url":"https://github.com/electrovir"},"sideEffects":false,"type":"module","main":"dist/index.js","module":"dist/index.js","types":"dist/index.d.ts","scripts":{"compile":"virmator compile","docs":"virmator docs","format":"virmator format","lint":"virmator lint fix","publish":"virmator publish npm run test:all","test":"virmator test web","test:all":"npm run compile && runstorm --names tests,spelling,format,docs,deps,lint \"npm run test:coverage\" \"npm run test:spelling\" \"npm run test:format\" \"npm run test:docs\" \"npm run test:deps\" \"npm run test:lint\"","test:coverage":"npm run test coverage","test:deps":"virmator deps check","test:docs":"virmator docs check","test:format":"virmator format check","test:lint":"virmator lint","test:spelling":"virmator spellcheck"},"dependencies":{"@augment-vir/common":"^32.2.1"},"devDependencies":{"@augment-vir/assert":"^32.2.1","@augment-vir/test":"^32.2.1","@eslint/eslintrc":"^3.3.6","@eslint/js":"10.0.1","@stylistic/eslint-plugin":"^5.10.0","@stylistic/eslint-plugin-ts":"^4.4.1","@typescript-eslint/eslint-plugin":"^8.65.0","@web/dev-server-esbuild":"^2.0.0","@web/test-runner":"^1.0.0","@web/test-runner-playwright":"^1.0.0","cspell":"^10.0.1","dependency-cruiser":"^18.1.0","esbuild":"^0.28.1","eslint":"^10.7.0","eslint-config-prettier":"^10.1.8","eslint-plugin-jsdoc":"^63.2.2","eslint-plugin-monorepo-cop":"^1.0.2","eslint-plugin-playwright":"^2.10.5","eslint-plugin-prettier":"^5.5.6","eslint-plugin-require-extensions":"^0.1.3","eslint-plugin-sonarjs":"^4.2.0","eslint-plugin-unicorn":"^72.0.0","istanbul-smart-text-reporter":"^1.1.5","markdown-code-example-inserter":"^3.0.6","npm-check-updates":"^22.2.9","prettier":"3.3.3","prettier-plugin-interpolated-html-tags":"^2.0.1","prettier-plugin-jsdoc":"^1.8.1","prettier-plugin-multiline-arrays":"~4.1.10","prettier-plugin-organize-imports":"^4.3.0","prettier-plugin-packagejson":"^3.0.2","prettier-plugin-sort-json":"^4.2.0","prettier-plugin-toml":"^2.0.6","typedoc":"^0.28.20","typescript":"^6.0.3","typescript-eslint":"8.65.0","virmator":"^14.30.0"},"engines":{"node":">=22"},"gitHead":"73d2f1a686996839a5eb68c45a19724e8d06cf4f","_id":"spdx-vir@1.0.0","_nodeVersion":"22.22.3","_npmVersion":"11.17.0","dist":{"integrity":"sha512-8MYbcJlTXj48ANJBs2JiWIuA2D+7lkA/D6TJt8St2QngLBzSR+cGsU2rOl62RJeoNAuUJvZtZ3oJA288Bp3jxA==","shasum":"198bd77e75504d3b116a85f585371aab1896e504","tarball":"https://registry.npmjs.org/spdx-vir/-/spdx-vir-1.0.0.tgz","fileCount":18,"unpackedSize":453252,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCJbDRVdZFoushlBXWW8R/JrK8WDyhm1/Vs7pZIeFad7AIhAPsCFOXNgMlKsBI5EqNkexgut2xKrg4llxgHJtq6R6Om"}]},"_npmUser":{"name":"electrovir","email":"pithy.gut0a@icloud.com"},"directories":{},"maintainers":[{"name":"electrovir","email":"pithy.gut0a@icloud.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/spdx-vir_1.0.0_1785331365352_0.6040258054683958"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-04T13:03:52.268Z","modified":"2026-07-29T13:22:45.654Z","0.0.0":"2026-06-04T13:03:52.501Z","0.0.1":"2026-06-04T14:42:12.779Z","0.0.2":"2026-07-13T15:15:21.731Z","1.0.0":"2026-07-29T13:22:45.504Z"},"bugs":{"url":"https://github.com/electrovir/spdx-vir/issues"},"author":{"name":"electrovir","url":"https://github.com/electrovir"},"license":"(MIT OR CC0-1.0)","homepage":"https://github.com/electrovir/spdx-vir","keywords":["SPDX","parse"],"repository":{"type":"git","url":"git+https://github.com/electrovir/spdx-vir.git"},"description":"Easy SPDX parsing.","maintainers":[{"name":"electrovir","email":"pithy.gut0a@icloud.com"}],"readme":"# spdx-vir\n\nParses and validates license strings strictly according to the SPDX grammar: https://spdx.github.io/spdx-spec/v2.3/SPDX-license-expressions.\n\nLicense ids have been extracted from https://spdx.org/licenses/licenses.json and exceptions from https://spdx.org/licenses/exceptions.json.\n\nBased on https://www.npmjs.com/package/spdx-expression-parse but more strict to the grammar and written in modern ESM syntax.\n\nTest it out here: https://codepen.io/electrovir/pen/yyVjVQR\n\n## Install\n\n```sh\nnpm i spdx-vir\n```\n\n## Usage\n\nValidating expressions:\n\n<!-- example-link: src/readme-examples/validate.example.ts -->\n\n```TypeScript\nimport {isValidSpdxExpression} from 'spdx-vir';\n\n// returns true\nisValidSpdxExpression('(MIT OR CC0-1.0)');\n\n// returns false\nisValidSpdxExpression('(MIT or CC0 1.0)');\n```\n\nParsing expressions:\n\n<!-- example-link: src/readme-examples/parse.example.ts -->\n\n```TypeScript\nimport {parseSpdxExpression, SpdxConjunction} from 'spdx-vir';\n\nparseSpdxExpression('(MIT OR CC0-1.0)');\n// outputs the following:\nconst output = {\n    conjunction: SpdxConjunction.OR,\n    left: {\n        license: 'MIT',\n    },\n    right: {\n        license: 'CC0-1.0',\n    },\n};\n\n// throws a SpdxParseError\nparseSpdxExpression('(MIT or CC0 1.0)');\n```\n","readmeFilename":"README.md"}