dmtrKovalenko / dmtrKovalenko/date-io
generic add/subtract methods?
Open
- Dominant language
- TypeScript
- Stars
- 754
- Forks
- 92
- PR merge metrics
- No merged PRs in 30d
Description
Given that we already have `(add/subtract)Days, Weeks, etc.` functions for every available `Unit`, is there a reason we don't define a generic `add/subtract` function that allows the called to pass in the unit dynamically?
```ts
add( value: TDate, unit: Unit, count: number )
subtract( value: TDate, unit: Unit, count: number )
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.