Reputation: 2081
I created a plugin with custom blocks. I am have trouble with the block preview. When I set the block on preview mode and reload the page editor — I get a error message on all the blocks I've preview Error loading block: You are probably offline.
In the console I am also getting the following errors:
pd-admin.js?ver=2.20:12 Uncaught TypeError: jQuery(...).live is not a function
Failed to load resource: net::ERR_CONNECTION_CLOSED
wp-auth-check.min.js?ver=5.5:2 Uncaught TypeError: Cannot read property 'hasClass' of undefined
Any ideas what I am doing to cause this?
I find issue with the RichText
field — if the RichText
is too long I can't preview the block at all and in the block I get the same error message saying Error loading block: You are probably offline.
Upvotes: 0
Views: 1483
Reputation: 28
To fix console error : WordPress 5.5 stopped using jQuery migrate. This change has been causing problems with old plugins and themes. If you are noticing issues after upgrading to WordPress 5.5, installing this plugin might fix it: https://wordpress.org/plugins/enable-jquery-migrate-helper/
For RichText
long text error, you need to increase LimitRequestLine
in your apache configuration. Ref : how to increase Apache 2 uri length limit
Upvotes: 1