@danielsimonjr/mathts-units 0.4.0 → 0.5.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/dist/index.js +1 -113
- package/package.json +17 -6
package/dist/index.js
CHANGED
|
@@ -1,113 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
Unit,
|
|
4
|
-
isUnit,
|
|
5
|
-
isUnitValue,
|
|
6
|
-
DimensionMismatchError,
|
|
7
|
-
UnitParseError,
|
|
8
|
-
DIMENSIONLESS,
|
|
9
|
-
dim,
|
|
10
|
-
UNIT_DIMENSION_LENGTH,
|
|
11
|
-
SI_DIMENSION_LENGTH,
|
|
12
|
-
toSiDimensions,
|
|
13
|
-
toSiDimensionVector,
|
|
14
|
-
fromSiDimensions,
|
|
15
|
-
fromSiDimensionVector,
|
|
16
|
-
BASE_UNITS,
|
|
17
|
-
DERIVED_UNITS,
|
|
18
|
-
ALL_UNITS,
|
|
19
|
-
UNIT_ALIASES,
|
|
20
|
-
getUnitDef,
|
|
21
|
-
SI_PREFIXES,
|
|
22
|
-
BEST_PREFIXES,
|
|
23
|
-
getPrefix,
|
|
24
|
-
UNIT_EXACT_SCALE,
|
|
25
|
-
PI_EXACT_SCALE,
|
|
26
|
-
LN2_EXACT_SCALE,
|
|
27
|
-
NAMED_IRRATIONALS,
|
|
28
|
-
namedIrrationalScale,
|
|
29
|
-
irrationalPower,
|
|
30
|
-
isRationalScale,
|
|
31
|
-
decimalExactScale,
|
|
32
|
-
exactScaleOf,
|
|
33
|
-
binaryExactScale,
|
|
34
|
-
ratioExactScale,
|
|
35
|
-
multiplyExactScales,
|
|
36
|
-
divideExactScales,
|
|
37
|
-
powerExactScale,
|
|
38
|
-
addExactScales,
|
|
39
|
-
exactScalesEqual,
|
|
40
|
-
exactScaleToNumber,
|
|
41
|
-
clearExactScaleNumberCache,
|
|
42
|
-
exactScaleNumberCacheSize,
|
|
43
|
-
formatExactScale,
|
|
44
|
-
readScaleExpression,
|
|
45
|
-
NAMED_SCALES,
|
|
46
|
-
UNIT_ROWS,
|
|
47
|
-
UNIT_ROW_ALIASES,
|
|
48
|
-
namedExactScale,
|
|
49
|
-
readUnitScale,
|
|
50
|
-
getUnitRow,
|
|
51
|
-
unitRowExactScale,
|
|
52
|
-
unitRowValue,
|
|
53
|
-
unitRowExactOffset,
|
|
54
|
-
UNIT_PREFIX_SETS,
|
|
55
|
-
unitPrefixExactScale,
|
|
56
|
-
getUnitPrefix
|
|
57
|
-
} from "@danielsimonjr/mathts-core";
|
|
58
|
-
export {
|
|
59
|
-
ALL_UNITS,
|
|
60
|
-
BASE_UNITS,
|
|
61
|
-
BEST_PREFIXES,
|
|
62
|
-
DERIVED_UNITS,
|
|
63
|
-
DIMENSIONLESS,
|
|
64
|
-
DimensionMismatchError,
|
|
65
|
-
LN2_EXACT_SCALE,
|
|
66
|
-
NAMED_IRRATIONALS,
|
|
67
|
-
NAMED_SCALES,
|
|
68
|
-
PI_EXACT_SCALE,
|
|
69
|
-
SI_DIMENSION_LENGTH,
|
|
70
|
-
SI_PREFIXES,
|
|
71
|
-
UNIT_ALIASES,
|
|
72
|
-
UNIT_DIMENSION_LENGTH,
|
|
73
|
-
UNIT_EXACT_SCALE,
|
|
74
|
-
UNIT_PREFIX_SETS,
|
|
75
|
-
UNIT_ROWS,
|
|
76
|
-
UNIT_ROW_ALIASES,
|
|
77
|
-
Unit,
|
|
78
|
-
UnitParseError,
|
|
79
|
-
addExactScales,
|
|
80
|
-
binaryExactScale,
|
|
81
|
-
clearExactScaleNumberCache,
|
|
82
|
-
decimalExactScale,
|
|
83
|
-
dim,
|
|
84
|
-
divideExactScales,
|
|
85
|
-
exactScaleNumberCacheSize,
|
|
86
|
-
exactScaleOf,
|
|
87
|
-
exactScaleToNumber,
|
|
88
|
-
exactScalesEqual,
|
|
89
|
-
formatExactScale,
|
|
90
|
-
fromSiDimensionVector,
|
|
91
|
-
fromSiDimensions,
|
|
92
|
-
getPrefix,
|
|
93
|
-
getUnitDef,
|
|
94
|
-
getUnitPrefix,
|
|
95
|
-
getUnitRow,
|
|
96
|
-
irrationalPower,
|
|
97
|
-
isRationalScale,
|
|
98
|
-
isUnit,
|
|
99
|
-
isUnitValue,
|
|
100
|
-
multiplyExactScales,
|
|
101
|
-
namedExactScale,
|
|
102
|
-
namedIrrationalScale,
|
|
103
|
-
powerExactScale,
|
|
104
|
-
ratioExactScale,
|
|
105
|
-
readScaleExpression,
|
|
106
|
-
readUnitScale,
|
|
107
|
-
toSiDimensionVector,
|
|
108
|
-
toSiDimensions,
|
|
109
|
-
unitPrefixExactScale,
|
|
110
|
-
unitRowExactOffset,
|
|
111
|
-
unitRowExactScale,
|
|
112
|
-
unitRowValue
|
|
113
|
-
};
|
|
1
|
+
export { ALL_UNITS, BASE_UNITS, BEST_PREFIXES, DERIVED_UNITS, DIMENSIONLESS, DimensionMismatchError, LN2_EXACT_SCALE, NAMED_IRRATIONALS, NAMED_SCALES, PI_EXACT_SCALE, SI_DIMENSION_LENGTH, SI_PREFIXES, UNIT_ALIASES, UNIT_DIMENSION_LENGTH, UNIT_EXACT_SCALE, UNIT_PREFIX_SETS, UNIT_ROWS, UNIT_ROW_ALIASES, Unit, UnitParseError, addExactScales, binaryExactScale, clearExactScaleNumberCache, decimalExactScale, dim, divideExactScales, exactScaleNumberCacheSize, exactScaleOf, exactScaleToNumber, exactScalesEqual, formatExactScale, fromSiDimensionVector, fromSiDimensions, getPrefix, getUnitDef, getUnitPrefix, getUnitRow, irrationalPower, isRationalScale, isUnit, isUnitValue, multiplyExactScales, namedExactScale, namedIrrationalScale, powerExactScale, ratioExactScale, readScaleExpression, readUnitScale, toSiDimensionVector, toSiDimensions, unitPrefixExactScale, unitRowExactOffset, unitRowExactScale, unitRowValue } from "@danielsimonjr/mathts-core";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@danielsimonjr/mathts-units",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "Standalone units & dimensional-analysis for MathTS -- the Unit class, unit registry, and SI prefixes, re-exported as a focused package",
|
|
5
5
|
"author": "Daniel Simon Jr.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
"README.md"
|
|
20
20
|
],
|
|
21
21
|
"scripts": {
|
|
22
|
-
"build": "
|
|
23
|
-
"dev": "
|
|
22
|
+
"build": "tsdown src/index.ts --format esm && tsc -p tsconfig.dts.json",
|
|
23
|
+
"dev": "tsdown src/index.ts --format esm --watch --on-success \"tsc -p tsconfig.dts.json\"",
|
|
24
24
|
"test": "bun test",
|
|
25
25
|
"test:watch": "vitest",
|
|
26
26
|
"test:coverage": "bun test --coverage",
|
|
@@ -28,15 +28,26 @@
|
|
|
28
28
|
"lint": "oxlint src",
|
|
29
29
|
"lint:fix": "oxlint src --fix",
|
|
30
30
|
"clean": "rm -rf dist",
|
|
31
|
-
"build:prod": "
|
|
31
|
+
"build:prod": "tsdown src/index.ts --format esm --minify && tsc -p tsconfig.dts.json"
|
|
32
|
+
},
|
|
33
|
+
"tsdown": {
|
|
34
|
+
"fixedExtension": false,
|
|
35
|
+
"dts": false,
|
|
36
|
+
"outputOptions": {
|
|
37
|
+
"comments": {
|
|
38
|
+
"legal": true,
|
|
39
|
+
"annotation": true,
|
|
40
|
+
"jsdoc": false
|
|
41
|
+
}
|
|
42
|
+
}
|
|
32
43
|
},
|
|
33
44
|
"dependencies": {
|
|
34
|
-
"@danielsimonjr/mathts-core": "^0.
|
|
45
|
+
"@danielsimonjr/mathts-core": "^0.19.0",
|
|
35
46
|
"typed-function": "^4.0.0"
|
|
36
47
|
},
|
|
37
48
|
"devDependencies": {
|
|
38
49
|
"@types/node": "^26.4.0",
|
|
39
|
-
"
|
|
50
|
+
"tsdown": "^0.23.0",
|
|
40
51
|
"typescript": "^7.0.2",
|
|
41
52
|
"vitest": "^5.0.0"
|
|
42
53
|
},
|