After this PR, should date-fns still give the choice of how to round a value? #2511
We've discussed this PR internally and have a couple of ideas - I will need to make some changes to these PRs.
The response to your question is 'Yes' - a rounding method will be passed in as an option with Math.floor as a default value.
I will delete the utils folder with the getRoundingMethod file - this will be replaced by getRoundingFn from src/_lib.
Object.is is not supported by IE hence we can't use it in the code.
The latest commit is my attempt to make changes to this PR - I will need to discuss this with @kossnocorp and if this approach is approved, we will be able to go ahead with the changes for the rest of differenceInXX functions.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.