How to support Underscores

If you are building a new theme with _s aka “Underscores” and wish to support Auto Load Next Post, then good for you because not only is _s the perfect base to build a new theme on, it only requires you to apply one filter to be ready for Auto Load Next Post.

Not all themes require this which is why I made a filter available for theme developers.

All you have to do is simply apply the code snippet below to your functions.php file and your new theme is ready to support Auto Load Next Post out of the box.

function _alnp_template_location() {
   return 'template-parts/';
}
add_filter('alnp_template_location', '_alnp_template_location');

Happy coding.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.