moment-range icon indicating copy to clipboard operation
moment-range copied to clipboard

Single moment range support and adjacent new ranges intersection interpretation

Open franjuan opened this issue 7 years ago • 2 comments

Single moment range support and testing and adjacent ranges intersection new interpretation

  • Added a whole set of unit test for single moment ranges (start == end)
  • All former unit tests kept in order to assure former behaviour for all operations
  • New interpretation of intersect operation through option.adjacent:true parameter (same behaviour assured if no parameter or false value). In such case (adjacent: true), {---}[---] adjacent ranges, returns a single moment range at the union point, instead of null

Thank you

franjuan avatar Mar 02 '17 22:03 franjuan

Hey @franjuan, could you explain why we'd need single moment ranges? I can't see the advantage over just using a moment object.

Rhysjc avatar Jul 26 '17 10:07 Rhysjc

Well, I would like to work indistinctly with ranges and moments, understandind that a Moment is a range of a single point

franjuan avatar Nov 30 '17 23:11 franjuan