chartjs / chartjs-adapter-date-fns

date-fns adapter for Chart.js
MIT License
107 stars 34 forks source link

Fix startOf function for isoWeek #22

Closed stockiNail closed 4 years ago

stockiNail commented 4 years ago

The startOf function is accepting a boolean for Sunday(false) and Monday(true).

Instead it should get the the week day (number) between 0 (Sunday) and 6(Saturday) in order to be more flexible to provide the startOf the week based on the parameter.

See https://github.com/chartjs/chartjs-adapter-luxon/issues/23

kurkle commented 4 years ago

It already works as expected.