Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

theme.json #55

Open
kauaicreative opened this issue Oct 15, 2021 · 3 comments
Open

theme.json #55

kauaicreative opened this issue Oct 15, 2021 · 3 comments

Comments

@kauaicreative
Copy link

Have you had a chance to check out the new theme.json system in WordPress 5.8

https://make.wordpress.org/core/2021/06/25/introducing-theme-json-in-wordpress-5-8/
"This new mechanism aims to take over and consolidate all the various add_theme_support calls... provides a way for theme authors to control these settings on a per-block basis "

@TeemuSuoranta
Copy link
Contributor

TeemuSuoranta commented Oct 15, 2021

We have followed development of theme.json to some degree but the first iterations have been somewhat unstable in the risk of compatibility in future. I've also heard some weird differences in HTML structure or styling with inline styles at the moment that will probably will be altered in the future so I'd recommend waiting still 1-3 releases before adopting it.

We can keep this issue open for all things related to theme.json before adopting it.

As a side note it is a bit bummer that it is a centralized file as it means that some logic for blocks will be outside modules but there might be ways to go around it in the future with filters.

@kauaicreative
Copy link
Author

Hi @TeemuSuoranta I've been wondering if you have had any ideas since WP 5.9 related to full site editing. It seems like a lot has changed. Also what do you think about multiple css files as described here? https://make.wordpress.org/core/2021/12/15/using-multiple-stylesheets-per-block/
Wondering how this could work in the Axio build system?

@TeemuSuoranta
Copy link
Contributor

I'd still wait a bit for full site editing as things seem a bit unstable for that at the moment and it is very opinionated subject. If agency is building tailored websites for clients the full site editing stuff will add bunch of work and in many cases is not needed or even wanted (higher learning curve and tighter control on layout).

Multiple stylesheets should be possible already and for example all modules should be able to add new stylesheets in their _.json. I'm a bit hesitant to really go full in separating the code for tens of stylesheets because even though it might give a small performance boost to some cases it may also cause issues with hosting providers that use HTTP requests as base of quota and cause more work for servers (and ultimately making carbon footprint of the website bigger). I guess there is some balancing to be done but I don't have really good idea where it is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants