wp_is_theme_directory_ignored() – Determines whether a theme directory should be ignored during export.
You appear to be a bot. Output may be restricted
Description
Determines whether a theme directory should be ignored during export.
Usage
$Bool = wp_is_theme_directory_ignored( $path );
Parameters
- $path
- ( string ) required – The path of the file in the theme.
Returns
Bool Whether this file is in an ignored directory.
Source
File name: wordpress/wp-includes/block-template-utils.php
Lines:
1 to 11 of 11
function wp_is_theme_directory_ignored( $path ) { $directories_to_ignore = array( '.DS_Store', '.svn', '.git', '.hg', '.bzr', 'node_modules', 'vendor' ); foreach ( $directories_to_ignore as $directory ) { if ( str_starts_with( $path, $directory ) ) { return true; } } return false; }