Closed iabhiyaan closed 3 years ago
editor.on('component:selected', (some, argument) => { console.log(some, argument); })
Well you can actually make use of custom render from blocks to apply custom DOM events.
blockManager.add('some-block-id', {
// ... block definition
render: ({ model, el }) => {
el.addEventListener('click', () => {
console.log('block', model)
})
},
});
Or Is there any way to listen for click event in block ?