Index: src/wp-includes/general-template.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- src/wp-includes/general-template.php	(revision 40821)
+++ src/wp-includes/general-template.php	(revision )
@@ -42,6 +42,16 @@
 
 	$templates[] = 'header.php';
 
+	/**
+	 * Filters the header templates.
+	 *
+	 * @since 4.8.0
+	 *
+	 * @param array $templates Templates of all possible headers.
+	 * @param string|null $name Name of the specific header file to use.
+	 */
+	$templates = apply_filters( 'get_header_templates', $templates, $name );
+
 	locate_template( $templates, true );
 }
 
@@ -81,6 +91,16 @@
 
 	$templates[]    = 'footer.php';
 
+	/**
+	 * Filters the footer templates.
+	 *
+	 * @since 4.8.0
+	 *
+	 * @param array $templates Templates of all possible footers.
+	 * @param string|null $name Name of the specific footer file to use.
+	 */
+	$templates = apply_filters( 'get_footer_templates', $templates, $name );
+
 	locate_template( $templates, true );
 }
 
@@ -119,6 +139,16 @@
 
 	$templates[] = 'sidebar.php';
 
+	/**
+	 * Filters the sidebar templates.
+	 *
+	 * @since 4.8.0
+	 *
+	 * @param array $templates Templates of all possible sidebars.
+	 * @param string|null $name Name of the specific sidebar file to use.
+	 */
+	$templates = apply_filters( 'get_sidebar_templates', $templates, $name );
+
 	locate_template( $templates, true );
 }
 
Index: src/wp-includes/template.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- src/wp-includes/template.php	(revision 40815)
+++ src/wp-includes/template.php	(revision )
@@ -643,6 +643,18 @@
 		}
 	}
 
+	/**
+	 * Filters the template location.
+	 *
+	 * @since 4.8.0
+	 *
+	 * @param string       $located        Path to the template location.
+	 * @param string|array $template_names Template file(s) to search for, in order.
+	 * @param boolean      $load           If true the template file will be loaded if it is found.
+	 * @param boolean      $require_once   Whether to require_once or require. Default true. Has no effect if $load is false.
+	 */
+	$located = apply_filters( 'located_template', $located, $template_names, $load, $require_once );
+
 	if ( $load && '' != $located )
 		load_template( $located, $require_once );
 
