ahmadawais / create-guten-block

📦 A zero-configuration #0CJS developer toolkit for building WordPress Gutenberg block plugins.
https://Awais.dev/cgb-post
MIT License
3.15k stars 328 forks source link

Loading backend styles in frontend: Unusable with Gutenberg 7.5 AND performance/GDPR issue #268

Closed mariohamann closed 4 years ago

mariohamann commented 4 years ago
  1. I created a completely clean WordPress-Website.
  2. I created a new block with create-guten-block: It loads all backend styles. -> Performance problem. Even a Google font style is being loaded and that's a real problem for GDPR.
  3. I installed Gutenberg 7.5: Backend styles are loaded and there is a new backend-style for mobile devices:
    html {
    position: fixed;
    width: 100%;
    }

    -> EVERY website with create-guten-block and Gutenberg 7.5 can't be scrolled on mobile

Without cgb-block: without-block-suite

With cgb-block with-block-suite

I can confirm for every website, every theme and every block I created with cgb and with Gutenberg 7.5. Issue in Gutenberg github: https://github.com/WordPress/gutenberg/issues/20214

ahmadawais commented 4 years ago

CGB gives you the code, you can edit all of it. If you can improve it, send in a PR. @asharirfan look into this.

mariohamann commented 4 years ago

I think it seems to relate to #210 and #267. (Didn't see it earlier, I'm sorry.)

Edit: Seems to be fixed, thank you, @Connum and @ahmadawais!

ahmadawais commented 4 years ago

This issue must have been solved via #267.

Successfully published:

You do have to manually update the init.php file like this.