Gutenberg wordpress javascript on editor
-
Hello all,
I have been struggling with this one for a while, I have recently switched from Flexible Layouts to Blocks using ACF. The issue I have now is, I have all my scripts in the scripts.js file, that initiates things like Slick Slider, and other custom code for elements.
While on the front-end the website looks normal, and all the block function as they should, the Javascript is not being loaded in the back-end editor. I tried including the script file, but it seems like the DOMLoaded event the preview of the block is still not being displayed, so the script never links up to it.
Is there any way to trigger the javascript for the blocks after they have been displayed in the preview editor.
- The topic ‘Gutenberg wordpress javascript on editor’ is closed to new replies.