custom component not able to display at first rendering in GrapesJs studio #6080
-
I am not able to see my custom component at the first time of my react application rendering , when i try to search it on the block section then its appers and after seraching it can be visible in block section . you can find my code below:- export default function App() { const handleEditorReady = (editorInstance) => {
}; useEffect(() => {
}, [editor]); const addCustomComponent = (editorInstance) => {
}; const setupStyleManager = (editorInstance) => {
}; const openCategory = (editorInstance, categoryName) => {
}; return ( Hello, World! ',}, ], styles: [ 'body { font-family: Arial, sans-serif; }', 'div { color: blue; }', ], custom: { js: "console.log('Hello, World!');", }, }; return { project: mockProject }; }, autosaveChanges: 100, autosaveIntervalMs: 10000, }, }} onReady={handleEditorReady} /> ); } |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Beta Was this translation helpful? Give feedback.
-
@artf , I have a question that , can we implement custom js in studio? means is there any embed js code functionality ? |
Beta Was this translation helpful? Give feedback.
#6081 (comment)