Local Data in the React Scheduler
The Syncfusion® React Scheduler component supports binding local datasets directly to display predefined data without server requests. This method enhances performance and enables offline functionality.
Assigning local JSON data
Bind a JSON array of appointment objects directly to eventSettings.dataSource. This method displays predefined events without network requests, making it suitable for static datasets and offline applications.
Loading data with useEffect
Use the useEffect hook to prepare or fetch data after the component mounts, then assign it to eventSettings.dataSource. This approach provides clean separation between data fetching and rendering logic.
Binding with React state
Connect the Scheduler's eventSettings.dataSource to a React state variable to enable real-time data synchronization. State changes automatically reflect in the Scheduler, making this ideal for dynamic applications with real-time editing, filtering, or data updates.