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
[Feedback Wanted] Directory structure question #171
Comments
Some themes use /includes/ others use /assets/, some even use /library/. Unless there is some kind of standard I missed? (Which is likely). To me, "assets" makes the most sense as they are pieces of code that belong to the theme. |
Thanks. To me assets is more CSS, JS, Images. But just wanted to ask the question. |
That's actually a great point. Definitely something to think about - especially since many themes seem to take that route. |
Just dropping my 2 cents for what it's worth. |
I'd love for WP to have some kind of standards/best practices when it came to file structure. |
Made some changes to the original post to get feedback from more users. 👍 |
I've always thought of includes to indicate server side and assets to indicate front end. Since the functions file uses include() to call up the functions files, it would probably make more sense for them to be in an includes directory. |
I'm also slightly irritated that the functions folder is located under assets. I would leave the name "functions", because of the relationship to functions.php, and would place the folder directly into the theme root. |
I'm still a pup learning WP, but when I worked with another CMS and it was set up just as @mrscharf stated. Is there any other files that would benefit from this? Also are you thinking having the includes folder on the same directory level as parts, assets, etc? |
@iamchaka - correct! If this change were to happen, the |
This change will happen in the next update. |
Just curious why your /functions/ are located in your /assets/ directory? Shouldn't they be in an /includes/ directory?
Edit from @JeremyEnglert - should the functions be moved from assets/functions to an includes/ directory? This seems to be how many themes have it setup.
The text was updated successfully, but these errors were encountered: