{"id":17004812,"url":"https://github.com/clickermonkey/dayspan","last_synced_at":"2025-04-06T19:12:34.453Z","repository":{"id":32499162,"uuid":"111052756","full_name":"ClickerMonkey/dayspan","owner":"ClickerMonkey","description":"A date \u0026 schedule library to use for advanced calendars in TypeScript and JS.","archived":false,"fork":false,"pushed_at":"2022-12-10T15:27:38.000Z","size":6305,"stargazers_count":140,"open_issues_count":27,"forks_count":21,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-03-30T17:11:12.010Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://clickermonkey.github.io/dayspan/docs/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ClickerMonkey.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":null,"patreon":"clickermonkey","open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"custom":null}},"created_at":"2017-11-17T03:26:37.000Z","updated_at":"2025-01-19T08:57:19.000Z","dependencies_parsed_at":"2022-07-12T16:09:40.865Z","dependency_job_id":null,"html_url":"https://github.com/ClickerMonkey/dayspan","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClickerMonkey%2Fdayspan","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClickerMonkey%2Fdayspan/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClickerMonkey%2Fdayspan/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClickerMonkey%2Fdayspan/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ClickerMonkey","download_url":"https://codeload.github.com/ClickerMonkey/dayspan/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247535519,"owners_count":20954576,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-14T04:44:31.655Z","updated_at":"2025-04-06T19:12:34.432Z","avatar_url":"https://github.com/ClickerMonkey.png","language":"TypeScript","readme":"# DaySpan\n\nA date \u0026 schedule library to use for advanced calendars in TypeScript and JS.\n\n- [Google Calendar Clone](https://clickermonkey.github.io/dayspan-vuetify/example/) checkout [dayspan-vuetify](https://github.com/ClickerMonkey/dayspan-vuetify)\n- [Documentation](https://clickermonkey.github.io/dayspan/docs/)\n- [Download JS](umd/dayspan.js)\n- Install via `bower install dayspan` or `npm install dayspan`\n\n### Features\n\n- Schedules track how frequent events occur using 20+ properties\n- Events can last minutes, hours, days, or weeks\n- Events can occur all day, or 1 or more times during the day\n- Events can have any day \u0026 time included as an event occurrence (they don't need to match the frequency of the schedule)\n- Events can be excluded, cancelled, or have metadata (specific event occurrence, all in a given day, week, month, quarter, or year)\n- Event occurrences can be moved\n- Calendars can represent a span of days, weeks, months, or years\n- Easily list the next/previous days that occur on a schedule\n- Describe a schedule in a human friendly string\n- Export and import schedules and calendars to plain objects for easy saving and loading\n- Provides logic to help display intersecting events on a calendar\n\n### TypeScript Example\n\n```typescript\n// A monthly calendar around today (string=event data type, any=schedule metadata type)\nlet cal = Calendar.months\u003cstring, any\u003e();\n\n// Every Monday 9:00 - 9:30\ncal.addEvent({\n  data: 'Weekly Meeting',\n  schedule: {\n    dayOfWeek: Weekday.MONDAY,\n    times: 9,\n    duration: 30,\n    durationUnit: 'minutes'\n  }\n});\n\n// Dr. Appointment on 01/04/2018\ncal.addEvent({\n  data: 'Dr. Appointment',\n  visible: false,\n  schedule: {\n    on: Day.build(2018, Month.APRIL, 1)\n  }\n});\n\n// Mother's Day\ncal.addEvent({\n  id: 'someUserProvidedId',\n  data: \"Mother's Day\",\n  schedule: new Schedule({\n    weekspanOfMonth: 1,         // 2nd\n    dayOfWeek: Weekday.SUNDAY,  // Sunday\n    month: Month.MAY            // of May\n  })\n});\n\n// The array of days in the month, each day has a list of the days events.\ncal.days;\n\n// Go to the next month\ncal.next();\n\n// Select this day and update the selection flags in the calendar days\ncal.select(Day.build(2018, Month.APRIL, 12));\n\n// Remove the schedule\ncal.removeEvent('Weekly Meeting');\n\n// A weekly calendar with custom MyEvent class\nCalendar.weeks\u003cMyEvent, any\u003e();\n\n// A daily calendar covering 3 days centered on today\nCalendar.days\u003cstring, any\u003e(3);\n\n// A daily calendar covering 3 days starting with given date\nCalendar.days\u003cstring, any\u003e(3, Day.build(2018, Month.JUNE, 15), 0);\n```\n\n### JS Example\n\nYou just need to append `ds` to the beginning of the classes:\n\n```javascript\n// A monthly calendar around today\nvar cal = ds.Calendar.months();\n\n// Every Monday 9:00 - 9:30\ncal.addEvent({\n  data: 'Weekly Meeting',\n  schedule: {\n    dayOfWeek: [ds.Weekday.MONDAY],\n    times: 9,\n    duration: 30,\n    durationUnit: 'minutes'\n  }\n});\n\n// Dr. Appointment on 01/04/2018\ncal.addEvent({\n  data: 'Dr. Appointment',\n  schedule: new ds.Schedule({\n    on: ds.Day.build(2018, ds.Month.APRIL, 1)\n  })\n});\n```\n","funding_links":["https://patreon.com/clickermonkey"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclickermonkey%2Fdayspan","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclickermonkey%2Fdayspan","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclickermonkey%2Fdayspan/lists"}