Read-only mode
info
In this mode you cannot create and edit tasks and links, and drag task bars.
To make the entire Gantt read-only, set the readonly
property to true and define it inside the Gantt tag.
import { getData } from "./data";
import { Gantt } from "wx-react-gantt";
import React, { useRef } from "react";
const MyComponent = () => {
const data = getData();
const readonly = true;
return <Gantt tasks={data.tasks} readonly={readonly} />;
};
export default MyComponent;