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

2.x Revert theme subfolder #139

Merged
merged 1 commit into from
Jul 28, 2023
Merged

2.x Revert theme subfolder #139

merged 1 commit into from
Jul 28, 2023

Conversation

gchtr
Copy link
Member

@gchtr gchtr commented Mar 14, 2023

In #103, all template files were moved into a subfolder for a better file structure. However, this leads to consequences like wrong paths for images (see timber/timber#2453).

We could fix these issues and work around it, but is it worth it? I don’t think the benefit of having a nicer file structure is bigger than having to manage various issues, because the file structure doesn’t follow the WordPress standard.

If people still wanted to use that structure, we could add filters in the appropriate places in Timber core that would allow them to fix these issues themselves. But we probably shouldn’t handle this case in Timber core itself.

This pull request reverts the changes in #103 and moves the theme files back to the root folder.

Having template files in a subfolder can lead to unexpected consequences, as we can see in timber/timber#2458. There may be other effects. Working around them is more tedious than the benefits a subfolder brings.
@szepeviktor
Copy link
Contributor

Oh nooo! I've even developed a solution for non-Composer installation (ZIP upload).
https://github.com/szepeviktor/wordpress-website-lifecycle/blob/master/mu-plugins/_core-theme-subdir.php

Copy link
Member

@nlemoine nlemoine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! 🙂

@gchtr gchtr merged commit 1254c2f into 2.x Jul 28, 2023
@gchtr gchtr deleted the 2.x-revert-theme-subfolder branch July 28, 2023 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants