Create an Event Calendar in React Using Schedule-X | Step-by-Step Tutorial

แชร์
ฝัง
  • เผยแพร่เมื่อ 19 ต.ค. 2024

ความคิดเห็น • 35

  • @ironvocal
    @ironvocal 23 วันที่ผ่านมา

    this is what exactly i was looking for, also the todo follow up, thanks mate!

  • @adam_frl
    @adam_frl หลายเดือนก่อน

    thank you for the insightful tutorial! it really helped me get up and running with the calendar!👍👍👍

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      Glad to hear it was helpful! Hope the calendar can be of good use to you 🙂

  • @mahmoodtareq3520
    @mahmoodtareq3520 หลายเดือนก่อน

    Thank you so much, Tom.
    Very well Explained.

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      Glad you liked it!

  • @feedback27
    @feedback27 23 วันที่ผ่านมา

    worked! and its very informative

  • @pathanfaizan4714
    @pathanfaizan4714 18 วันที่ผ่านมา

    On event click i want to open my custom model with my custom details what can i do? ?

    • @TomÖsterlund
      @TomÖsterlund  18 วันที่ผ่านมา +1

      In Schedule-X there is a feature called custom components, with which you can inject your own custom React components.
      It's documented here: schedule-x.dev/docs/frameworks/react#custom-components
      Using that feature you can create your own custom modal

  • @shironeko1864
    @shironeko1864 4 วันที่ผ่านมา

    How to in integration state by data call API bro?

    • @TomÖsterlund
      @TomÖsterlund  4 วันที่ผ่านมา

      There is a plugin called the events service, with which you can add data after having rendered the calendar: schedule-x.dev/docs/calendar/plugins/events-service

  • @ZainInam-h3q
    @ZainInam-h3q 17 วันที่ผ่านมา

    Can we send the mail to candidates like Google Calendar?

    • @TomÖsterlund
      @TomÖsterlund  15 วันที่ผ่านมา +1

      This is a frontend component, so it does not deal with mailing or any other backend tasks

    • @ZainInam-h3q
      @ZainInam-h3q 13 วันที่ผ่านมา

      @@TomÖsterlund Got it. Thanks for the reply

  • @PhuongNguyen-zf8wt
    @PhuongNguyen-zf8wt หลายเดือนก่อน

    what about when i get data from backend and set to events is it work ?

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      Sure thing! You can achieve this with the events service plugin. It's documented under "plugins" in the docs

    • @PhuongNguyen-zf8wt
      @PhuongNguyen-zf8wt หลายเดือนก่อน

      @@TomÖsterlund i wish you will make this kind of tutorial in the future (generate data schedule from an api). It will contribute your commiunity so much

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      @@PhuongNguyen-zf8wt any specific type of API you have in mind?

  • @ngChinh04
    @ngChinh04 หลายเดือนก่อน

    how can i change the detail of event when click on it? Tks

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      There is a callback option that you can add in the config called `callbacks.onEventClick`, which takes the the clicked event as it's only parameter.

  • @PhuongNguyen-zf8wt
    @PhuongNguyen-zf8wt หลายเดือนก่อน

    and how to style event modal bro ?

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      You can either just write your custom style overrides for this, or you can even replace its content by using custom components. Custom components is a feature of the framework adapters (like for Vue, React, Angular etc.). Are you using any of those?

  • @axellondas6297
    @axellondas6297 หลายเดือนก่อน

    how to catch the case when i click on event ?

    • @axellondas6297
      @axellondas6297 หลายเดือนก่อน

      2 and half after reading the doc i found the way you have to use callbacks
      this is the code
      ```jsx
      export const Calendar = () => {
      const onEventClick = useCallback((event) => {
      console.log('Event clicked:', event);
      // Add your custom logic here
      }, []);
      const calendar = useNextCalendarApp({
      views: [createViewMonthGrid(), createViewMonthAgenda(), createViewDay(), createViewWeek()],
      events: [
      {
      id: '1',
      title: 'Event 1',
      start: '2023-12-16 10:00',
      end: '2023-12-16 12:00',
      },
      ],
      selectedDate: '2023-12-16',
      callbacks: {
      onEventClick,
      },
      })
      return (

      );
      };
      ```

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      You can add a `callbacks` section to the config object, and then add a callback `onEventClick`: schedule-x.dev/docs/calendar/configuration

  • @axellondas6297
    @axellondas6297 หลายเดือนก่อน

    how to change event color ?

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      For this you can use the "calendars" feature: schedule-x.dev/docs/calendar/calendars

  • @AaishaDev
    @AaishaDev หลายเดือนก่อน

    Can i have agenda view in this?

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน +1

      Yes! there is an agenda view. The function you need to import is called `createViewMonthAgenda`

    • @AaishaDev
      @AaishaDev หลายเดือนก่อน

      @@TomÖsterlund I've already added this function, but in the I only see three views which is day, week and month
      I'm using Reactjs, I really need to implement agenda view, will you please help

    • @AaishaDev
      @AaishaDev หลายเดือนก่อน

      ​@@TomÖsterlund I've already added this function, but in the UI I only see three views which is day, week and month
      I'm using Reactjs, I really need to implement agenda view, will you please help

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน +1

      @@AaishaDev I see! The month agenda view was initially thought to be the mobile version of the month view, so it is only visible by default when the calendar is not so wide.
      You can override this behavior by doing this:
      const agenda = createViewMonthAgenda()
      agenda.hasWideScreenCompat = true

    • @AaishaDev
      @AaishaDev หลายเดือนก่อน

      @@TomÖsterlund Thankyou, it worked

  • @yashkelhe376
    @yashkelhe376 หลายเดือนก่อน

    Bro use dark theme mode 🥲

    • @TomÖsterlund
      @TomÖsterlund  หลายเดือนก่อน

      never 😃
      I switched 3 years ago and just love working in light mode