Skip to content

📅 Convert ICS calendars (eg. Google Calendar) to an opinionated JSON format.

Notifications You must be signed in to change notification settings

nnessgmbh/ics-to-json

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ics-to-json


Convert the ICS calendar format to JSON data to consume in web apps.

Usage

import icsToJson from 'ics-to-json'

// Get ICS text however you like, example below
// Make sure you have the right CORS settings if needed
const convert = async (fileLocation) => {
	const icsRes = await fetch(fileLocation)
	const icsData = await icsRes.text()
	// Convert
	const data = icsToJson(icsData)
	return data
}

Format

Result is an array of:

{
  startDate: '20180505T020000Z',
  endDate: '20180505T060000Z',
  description: 'Big Event!',
  location: 'The place!',
  summary: 'Summary!'
}

Upcoming

  • Ability to reverse conversion
  • Include the rest of the keys from the ICS format

About

📅 Convert ICS calendars (eg. Google Calendar) to an opinionated JSON format.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%