dayjs icon indicating copy to clipboard operation
dayjs copied to clipboard

feat: add diff360 plugin

Open ERPedersen opened this issue 3 years ago • 1 comments

This plugin returns the number of days between two dates based on a 360-day calendar (twelve 30-day months),

The 360-day calendar is a method of measuring durations used in financial markets, in computer models, in ancient literature, and in prophetic literary genres.

It uses the following algorithm to calculate the difference (Turn off dark mode to see):

image

ERPedersen avatar Jun 02 '22 14:06 ERPedersen

Thanks!

In order to keep the same API with moment.js, we intend to not accept custom plugins that have different APIs with moment.js.

It will be better to publish it as an npm package and manage it yourself.

iamkun avatar Jun 27 '22 15:06 iamkun