How to use date-easter - 3 common examples

To help you get started, we’ve selected a few date-easter examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github commenthol / date-holidays-parser / src / Easter.js View on Github external
constructor (opts) {
    opts = opts || {}
    super(opts)

    this._fn = easter.easter
    if (opts.type === 'orthodox') {
      this._fn = easter.orthodoxEaster
    }
  }
github gadael / icsdb / src / specialevents.js View on Github external
function updateEasterMonday(events, from, to) {

    let eastermonday = getEventByUid(events, '5bd21657-4072-4474-8007-4ffd522fea87');

    if (null === eastermonday) {
        return;
    }


    let e, easter, estermondayDates = [];


    for (let y = from; y< to; y++) {
        e = dateEaster.gregorianEaster(y);

        easter = new Date(e.year, e.month-1, e.day);
        estermondayDates.push(nextMonday(easter));
    }

    eastermonday.setProperty('RDATE', estermondayDates, { VALUE: 'DATE' });
}
github commenthol / date-holidays-parser / src / Easter.js View on Github external
constructor (opts) {
    opts = opts || {}
    super(opts)

    this._fn = easter.easter
    if (opts.type === 'orthodox') {
      this._fn = easter.orthodoxEaster
    }
  }

date-easter

Calculates Easter for a given year

MIT
Latest version published 1 month ago

Package Health Score

74 / 100
Full package analysis