You need that for child themes. If you have a separate header.php
a child theme can use its own header.php
and override the parent theme’s file. Plus, header.php
and footer.php
are used in wp-signup.php
.
Another reason is readability: Putting all the code for a theme into just one file gets very messy very fast.
A use case for a compact theme is testing and debugging: My Mini Theme uses just index.php
and comments.php
for output. Whenever a plugin doesn’t do what I expected I use that theme to be sure it is not a theme issue.