Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/webpack/webpack
/ negate
Function
negate
lib/util/semver.js:178–180 ·
view source on GitHub ↗
(range)
Source
from the content-addressed store, hash-verified
176
* @returns {SemVerRangeItem[]} result
177
*/
178
const
negate = (range) => {
179
return
[-(/** @
type
{ [number]} */ (range)[0]) - 1, ...range.slice(1)];
180
};
181
182
/**
183
* Returns the sem ver range.
Callers
2
parseSimple
Function · 0.85
parseRange
Function · 0.85
Calls
1
slice
Method · 0.80
Tested by
no test coverage detected