This repository has been archived by the owner on Sep 8, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 62
/
functions.php
45 lines (40 loc) · 1.72 KB
/
functions.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
/**
* Some Like it Neat functions and definitions
*
* @package Some_Like_It_Neat
* @author Alex Vasquez <alex@digisavvy.com>
* @license GPL-2.0+ https://www.gnu.org/licenses/old-licenses/gpl-2.0.en.html
* @link https://github.com/digisavvy/some-like-it-neat
*
* The $some_like_it_neat_includes array includes a variety of scripts, styles, and functions among other
* useful utilities for your theme.
*
* Add or remove files to the array as needed. Supports child theme overrides.
*
* Please note that missing files will produce a fatal error.
*
* You don't have to include your code in these include files. You can insert your own code below as well.
*
* @link https://github.com/digisavvy/some-like-it-neat/commit/636baf7e8b2fefdcf79fd518622f35fa933c7e2f
*/
$some_like_it_neat_includes = [
'library/assets.php', // Scripts and stylesheets.
'library/widgets.php', // Widgets.
'library/theme-setup.php', // Theme setup.
'library/vendors/meta.php', // Theme Meta.
'library/extras.php', // Extra and nifty things.
'library/vendor.php', // 3rd party scripts/code etc.
'library/customizer-frontend-settings.php', // Theme customizer related.
'library/structure/header.php', // Include header markup, supports beaver themer.
'library/structure/footer.php', // Include footer markup, supports beaver themer.
'library/structure/content.php', // Include content area markup, supports beaver themer.
];
foreach ( $some_like_it_neat_includes as $file ) {
if ( ! $filepath = locate_template( $file ) ) {
/* translators: %s: Name of current post. Only visible to screen readers */
sprintf( __( 'Error locating %s for inclusion', 'some_like_it_neat' ), $file );
}
include_once $filepath;
}
unset( $file, $filepath );