source:
node_modules/es-toolkit/dist/compat/util/gt.mjs@
ba17441
| Last change on this file since ba17441 was a762898, checked in by , 5 months ago | |
|---|---|
|
|
| File size: 238 bytes | |
| Rev | Line | |
|---|---|---|
| [a762898] | 1 | import { toNumber } from './toNumber.mjs'; |
| 2 | ||
| 3 | function gt(value, other) { | |
| 4 | if (typeof value === 'string' && typeof other === 'string') { | |
| 5 | return value > other; | |
| 6 | } | |
| 7 | return toNumber(value) > toNumber(other); | |
| 8 | } | |
| 9 | ||
| 10 | export { gt }; |
Note:
See TracBrowser
for help on using the repository browser.
