Hi Naman Aggarwal,
Greetings from Syncfusion support.
Based on your shared details, we suspect that you are expecting the functional component in react platform using react hooks. For your reference, we have render the DashboardLayout component as a functional component.
Refer the below code snippet.
|
function App() {
function onclick() {
alert("event triggered");
}
function pieTemplate(args) {
return (
<div>
<ButtonComponent onClick={onclick}>Decrement</ButtonComponent>
</div>
);
}
return (
<div className="App">
<DashboardLayoutComponent
id="edit_dashboard"
columns={6}
allowResizing={true}
allowDragging={true}
>
<PanelsDirective>
<PanelDirective
sizeX={3}
sizeY={2}
row={0}
col={0}
content={pieTemplate}
header="<div>Panel 1</div>"
/>
</PanelsDirective>
</DashboardLayoutComponent>
</div>
);
} |
Please, refer the below sample link.
Could you please ensure the above sample. If we misunderstood your requirement, could you please share more details for your requirement. . It will be help us to provide you the prompt solution.
Please, refer the below links for DashboardLayout component.
Please let us know, if you need any further assistance.
Regards,
Sowmiya.P