Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter lxbdr

    (@lxbdr)

    I found the issue. The behavior that I described is already the default for the RichText component. The problem was

    1. I disabled the core/paragraph block which is the default to be inserted

    2. I was missing the necessary block transforms to core/paragraph and my other blocks which are needed for the expected behavior

    • This reply was modified 12 months ago by lxbdr. Reason: mark resolved
    lxbdr

    (@lxbdr)

    If you’re using the wp-scripts package for building your blocks you can use the --hot option which enables HMR in the editor. Important: You need to set the constant SCRIPT_DEBUG to true in your wp-config.php.

    In my case I also needed to enqueue the runtime separately when using hot reload. This is my enqueue script: https://gist.github.com/lxbdr/2d2120804ad400aaeb6ef21eed088e8a (Adjust constants accordingly)

    For the frontend part:
    When using save.js you need to save your block and manually refresh it on the frontend. Unless you’re using tailwind you’ll likely have few changes to the markup during development and a lot of changes to the stylesheet. You can load your folder in the Chrome dev tools workspace which will automatically inject changes without a page reload. Or try a setup with browser-sync which can also inject updated files without a full page reload.

    If your are using the render.php you could set up a watcher using browser-sync to reload if the file changes.

    Hi @mihche,
    I encountered the same problem. I solved it for now by setting my rules via the Themes Custom Css option, but this is not applied to the login page where everything is a little thight and I would need an some margin for the inline badge.. Can you help me with that?

Viewing 3 replies - 1 through 3 (of 3 total)