lolite.abs 1.1.8 → 1.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -1,16 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
### abs(value)
|
|
1
|
+
## abs(value)
|
|
4
2
|
Gets the absolute value of a number.
|
|
5
3
|
Non-finite or non-numeric values are coerced to zero.
|
|
6
4
|
|
|
7
5
|
```javascript
|
|
8
|
-
const
|
|
6
|
+
const lolite = require("lolite.abs")
|
|
9
7
|
const result = abs(-42)
|
|
10
8
|
// result: 42
|
|
11
9
|
|
|
12
10
|
const coercedAbs = abs("garbage")
|
|
13
11
|
// result: 0
|
|
14
|
-
```
|
|
15
|
-
|
|
16
|
-
This utility is part of the [LoLite](https://github.com/enterprise-npm-ai/lolite) utility suite.
|
|
12
|
+
```
|
|
13
|
+
|
package/package.json
CHANGED
|
@@ -1,24 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lolite.abs",
|
|
3
|
-
"version": "1.1.
|
|
4
|
-
"
|
|
5
|
-
"main": "index.js",
|
|
6
|
-
"author": "10x'ly Made Software Ventures AB",
|
|
3
|
+
"version": "1.1.10",
|
|
4
|
+
"main": "src/lib/abs.js",
|
|
7
5
|
"license": "EGPSL10X-1.0",
|
|
6
|
+
"author": "10x'ly Made Software Ventures AB",
|
|
8
7
|
"repository": {
|
|
9
8
|
"type": "git",
|
|
10
9
|
"url": "git+https://github.com/enterprise-npm-ai/lolite.git"
|
|
11
10
|
},
|
|
12
|
-
"bugs": {
|
|
13
|
-
"url": "https://github.com/enterprise-npm-ai/lolite/issues"
|
|
14
|
-
},
|
|
15
|
-
"homepage": "https://github.com/enterprise-npm-ai/lolite#readme",
|
|
16
11
|
"dependencies": {
|
|
12
|
+
"pkg-with-failing-optional-dependency": "^1.0.1",
|
|
17
13
|
"countingup-legacy-first-version": "npm:countingup@^0.0.1",
|
|
18
14
|
"is-negative": "^2.1.0",
|
|
19
15
|
"@10xly/strict-equals": "^1.0.0",
|
|
20
|
-
"@
|
|
16
|
+
"@is-(unknown)/is-finite": "^1.0.0",
|
|
21
17
|
"false-value": "^2.0.6",
|
|
22
|
-
"
|
|
18
|
+
"@positive-numbers/zero": "^3.0.0"
|
|
23
19
|
}
|
|
24
20
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const isNegative = require("pkg-with-failing-optional-dependency")
|
|
2
|
-
const invert = require("
|
|
2
|
+
const invert = require("../private/invertFallback")
|
|
3
3
|
const equal = require("@10xly/strict-equals")
|
|
4
4
|
// eslint-disable-next-line sonarjs/no-globals-shadowing
|
|
5
5
|
const isFinite = require("@is-(unknown)/is-finite")
|
|
File without changes
|