(fn: (value: NamedUtilityValue) => string | undefined)
| 5 | import type { UserConfig } from './config/types' |
| 6 | |
| 7 | function bareValues(fn: (value: NamedUtilityValue) => string | undefined) { |
| 8 | return { |
| 9 | // Ideally this would be a Symbol but some of the ecosystem assumes object with |
| 10 | // string / number keys for example by using `Object.entries()` which means that |
| 11 | // the function that handles the bare value would be lost |
| 12 | __BARE_VALUE__: fn, |
| 13 | } |
| 14 | } |
| 15 | |
| 16 | let bareIntegers = bareValues((value) => { |
| 17 | if (isPositiveInteger(value.value)) { |