Closed WhyNotHugo closed 2 years ago
Potential follow-up improvements:
RRULE
RRULE
, DTSTART
and exclusion rules, and returns a single rrule.Set
Add a function which parses RRULE, DTSTART and exclusion rules, and returns a single rrule.Set
I will likely follow-up with it since I'll eventually need it. I just need to re-read the relevant bits of the RFC t make sure I don't miss anything.
On another subject: There seems to be a bit of duplication between Prop.DateTime
and Props.DateTime
and others. Is one preferred and the other deprecated, or do they have distinct use cases?
On another subject: There seems to be a bit of duplication between Prop.DateTime and Props.DateTime and others. Is one preferred and the other deprecated, or do they have distinct use cases?
They are distinct use-cases: Props.DateTime
is useful when there's only a single prop with the supplied name. ical supports multiple props with the same name, in which case callers need to use Prop.DateTime
. In the RFC, see "The following […] MAY occur more than once" in the ABNF.
Ah, makes sense.
So RecurrenceRule
is definitely in the right place. :)
This relies on rrule-go, which implements RRULEs logic itself. The helper merely returns an
ROption
object.See the inline documentation for Props.ROption for finer details.