Code Organization

Code

Code that is specific to a child-theme page template should be placed in that page template file. (The permitted exception is home.php, for no other reason than that’s what we’ve got used to).

Admin UI

Additional settings screens or option boxes should go in a childthemename-theme-settings.php file.

Editor UI

Additional Editor metaboxes (post/page editor etc) should go in a childthemename-inpost-metaboxes.php file

Javascript

Javascript used in front-end should go in a /lib/js folder and javascript used in admin should go in a /lib/js/admin folder.

Script and Additional CSS

Script and additional CSS should be loaded via functions.php

Leave a Reply