lombardi 1.0.0 → 3.0.0
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/LICENSE.txt +1 -1
- package/README.md +7 -15
- package/dist/index.cjs +19 -0
- package/dist/index.d.cts +14 -0
- package/dist/index.d.mts +14 -0
- package/dist/index.mjs +18 -0
- package/package.json +43 -13
- package/index.js +0 -5
package/LICENSE.txt
CHANGED
package/README.md
CHANGED
|
@@ -1,39 +1,31 @@
|
|
|
1
1
|
# lombardi
|
|
2
2
|
|
|
3
|
-
[![Build Status][travis-svg]][travis]
|
|
4
|
-
[![Dependency Status][gemnasium-svg]][gemnasium]
|
|
5
|
-
|
|
6
3
|
[Lombardi's formula][1] for one-repetition maximum.
|
|
7
4
|
|
|
8
5
|
## Example
|
|
9
6
|
|
|
10
|
-
```
|
|
11
|
-
|
|
7
|
+
```javascript
|
|
8
|
+
import { lombardi } from 'lombardi';
|
|
12
9
|
|
|
13
10
|
lombardi(100, 10);
|
|
14
|
-
// => 125
|
|
11
|
+
// => 125.89254117941672
|
|
15
12
|
```
|
|
16
13
|
|
|
17
14
|
## Installation
|
|
18
15
|
|
|
19
|
-
```
|
|
16
|
+
```bash
|
|
20
17
|
$ npm install lombardi
|
|
21
18
|
```
|
|
22
19
|
|
|
23
20
|
## API
|
|
24
21
|
|
|
25
|
-
```
|
|
26
|
-
|
|
22
|
+
```javascript
|
|
23
|
+
import { lombardi } from 'lombardi';
|
|
27
24
|
```
|
|
28
25
|
|
|
29
|
-
### `lombardi(weight, reps)`
|
|
26
|
+
### `lombardi(weight: number, reps: number)`
|
|
30
27
|
|
|
31
28
|
Given _Number_ `weight` and _Number_ `reps`, returns the one-repetition maximum
|
|
32
29
|
from Lombardi's formula as a _Number_.
|
|
33
30
|
|
|
34
|
-
|
|
35
31
|
[1]: https://en.wikipedia.org/wiki/One-repetition_maximum#Lombardi
|
|
36
|
-
[travis]: https://travis-ci.org/KenanY/lombardi
|
|
37
|
-
[travis-svg]: https://img.shields.io/travis/KenanY/lombardi.svg
|
|
38
|
-
[gemnasium]: https://gemnasium.com/KenanY/lombardi
|
|
39
|
-
[gemnasium-svg]: https://img.shields.io/gemnasium/KenanY/lombardi.svg
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
// src/index.ts
|
|
3
|
+
/**
|
|
4
|
+
* Estimates a one-repetition maximum using Lombardi's formula.
|
|
5
|
+
*
|
|
6
|
+
* @param weight The weight lifted.
|
|
7
|
+
* @param reps The number of repetitions performed with `weight`.
|
|
8
|
+
* @returns The estimated one-repetition maximum.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* lombardi(100, 10);
|
|
13
|
+
* // => 125.89254117941672
|
|
14
|
+
* ```
|
|
15
|
+
*/
|
|
16
|
+
function lombardi(weight, reps) {
|
|
17
|
+
return weight * reps ** .1;
|
|
18
|
+
}
|
|
19
|
+
exports.lombardi = lombardi;
|
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Estimates a one-repetition maximum using Lombardi's formula.
|
|
3
|
+
*
|
|
4
|
+
* @param weight The weight lifted.
|
|
5
|
+
* @param reps The number of repetitions performed with `weight`.
|
|
6
|
+
* @returns The estimated one-repetition maximum.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```ts
|
|
10
|
+
* lombardi(100, 10);
|
|
11
|
+
* // => 125.89254117941672
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
14
|
+
export declare function lombardi(weight: number, reps: number): number;
|
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Estimates a one-repetition maximum using Lombardi's formula.
|
|
3
|
+
*
|
|
4
|
+
* @param weight The weight lifted.
|
|
5
|
+
* @param reps The number of repetitions performed with `weight`.
|
|
6
|
+
* @returns The estimated one-repetition maximum.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```ts
|
|
10
|
+
* lombardi(100, 10);
|
|
11
|
+
* // => 125.89254117941672
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
14
|
+
export declare function lombardi(weight: number, reps: number): number;
|
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// src/index.ts
|
|
2
|
+
/**
|
|
3
|
+
* Estimates a one-repetition maximum using Lombardi's formula.
|
|
4
|
+
*
|
|
5
|
+
* @param weight The weight lifted.
|
|
6
|
+
* @param reps The number of repetitions performed with `weight`.
|
|
7
|
+
* @returns The estimated one-repetition maximum.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* lombardi(100, 10);
|
|
12
|
+
* // => 125.89254117941672
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
function lombardi(weight, reps) {
|
|
16
|
+
return weight * reps ** .1;
|
|
17
|
+
}
|
|
18
|
+
export { lombardi };
|
package/package.json
CHANGED
|
@@ -1,27 +1,57 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lombardi",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"description": "Lombardi's formula for one-rep max",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"weight-training"
|
|
7
7
|
],
|
|
8
|
-
"repository": "KenanY/lombardi",
|
|
9
8
|
"license": "MIT",
|
|
10
|
-
"author": "Kenan Yildirim <kenan@kenany.me> (
|
|
11
|
-
"
|
|
9
|
+
"author": "Kenan Yildirim <kenan@kenany.me> (https://kenany.me/)",
|
|
10
|
+
"repository": {
|
|
11
|
+
"type": "git",
|
|
12
|
+
"url": "git+https://github.com/kenany/lombardi.git"
|
|
13
|
+
},
|
|
14
|
+
"type": "commonjs",
|
|
15
|
+
"types": "dist/index.d.cts",
|
|
16
|
+
"main": "dist/index.cjs",
|
|
17
|
+
"exports": {
|
|
18
|
+
".": {
|
|
19
|
+
"import": "./dist/index.mjs",
|
|
20
|
+
"require": "./dist/index.cjs"
|
|
21
|
+
},
|
|
22
|
+
"./*.mjs": {
|
|
23
|
+
"default": "./dist/*.mjs"
|
|
24
|
+
},
|
|
25
|
+
"./*.cjs": {
|
|
26
|
+
"default": "./dist/*.cjs"
|
|
27
|
+
},
|
|
28
|
+
"./*": {
|
|
29
|
+
"import": "./dist/*.mjs",
|
|
30
|
+
"require": "./dist/*.cjs"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
12
33
|
"files": [
|
|
13
|
-
"
|
|
34
|
+
"dist",
|
|
14
35
|
"LICENSE.txt"
|
|
15
36
|
],
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
},
|
|
19
|
-
"scripts": {
|
|
20
|
-
"test": "tape test/index.js"
|
|
37
|
+
"engines": {
|
|
38
|
+
"node": "^22.12.0 || 24 || >=26"
|
|
21
39
|
},
|
|
22
40
|
"devDependencies": {
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"
|
|
41
|
+
"@biomejs/biome": "2.6.9",
|
|
42
|
+
"@containerbase/semantic-release-pnpm": "1.4.4",
|
|
43
|
+
"@kenan/biome-config": "1.5.0",
|
|
44
|
+
"conventional-changelog-conventionalcommits": "9.3.1",
|
|
45
|
+
"publint": "0.3.25",
|
|
46
|
+
"semantic-release": "26.0.1",
|
|
47
|
+
"tsdown": "0.23.7",
|
|
48
|
+
"typescript": "7.0.2",
|
|
49
|
+
"vitest": "5.1.2"
|
|
50
|
+
},
|
|
51
|
+
"scripts": {
|
|
52
|
+
"build": "tsdown && tsc --noEmit",
|
|
53
|
+
"lint": "biome check",
|
|
54
|
+
"test": "vitest run",
|
|
55
|
+
"publint": "publint --strict"
|
|
26
56
|
}
|
|
27
57
|
}
|