How to use the ics.createEvent function in ics

To help you get started, we’ve selected a few ics 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 opencollective / opencollective-api / server / models / Collective.js View on Github external
description,
          start,
          end,
          location,
          url,
          status: 'CONFIRMED',
          organizer: {
            name: parentCollective.name,
            email: `hello@${parentCollective.slug}.opencollective.com`,
          },
          alarms,
        };
        if (this.location.lat) {
          event.geo = { lat: this.location.lat, lon: this.location.long };
        }
        ics.createEvent(event, (err, res) => {
          if (err) {
            console.error(`Error while generating the ics file for event id ${this.id} (${url})`, err);
          }
          return resolve(res);
        });
      });
    });
github comatory / fb2iCal / lib / services / ics-generator.js View on Github external
return new Promise((resolve, reject) => {
    ics.createEvent(data, (err, value) => {
      if (err) {
        reject(err)
        return
      }

      resolve(value)
    })
  })
}
github opencollective / opencollective-api / server / models / Collective.js View on Github external
description,
          start,
          end,
          location,
          url,
          status: 'CONFIRMED',
          organizer: {
            name: parentCollective.name,
            email: `hello@${parentCollective.slug}.opencollective.com`,
          },
          alarms,
        };
        if (this.location.lat) {
          event.geo = { lat: this.location.lat, lon: this.location.long };
        }
        ics.createEvent(event, (err, res) => {
          if (err) {
            logger.error(`Error while generating the ics file for event id ${this.id} (${url})`, err);
          }
          return resolve(res);
        });
      });
    });

ics

iCal (ics) file generator

ISC
Latest version published 2 months ago

Package Health Score

81 / 100
Full package analysis