WordPress at a glance
function is not described

require_if_theme_supports() WP 2.9.0

Checks a theme's support for a given feature before loading the functions which implement it.

No Hooks.

Return

true/false. True if the current theme supports the supplied feature, false otherwise.

Usage

require_if_theme_supports( $feature, $include );
$feature(string) (required)
The feature being checked.
$include(string) (required)
Path to the file.

Code of require if theme supports: wp-includes/theme.php WP 5.2.1

<?php
function require_if_theme_supports( $feature, $include ) {
	if ( current_theme_supports( $feature ) ) {
		require( $include );
		return true;
	}
	return false;
}