WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
функция не описана

Yoast\WP\SEO\Generators\Schema

Author::generate() public Yoast 1.0

Returns Person Schema data.

{} Это метод класса: Author{}

Хуков нет.

Возвращает

true|false|Массив. Person data on success, false on failure.

Использование

$Author = new Author();
$Author->generate();

Код Author::generate() Yoast 17.2

public function generate() {
	$user_id = $this->determine_user_id();
	if ( ! $user_id ) {
		return false;
	}

	$data = $this->build_person_data( $user_id );

	if ( $this->site_represents_current_author() === false ) {
		$data['@type'] = [ 'Person' ];
		unset( $data['logo'] );
	}

	// If this is an author page, the Person object is the main object, so we set it as such here.
	if ( $this->context->indexable->object_type === 'user' ) {
		$data['mainEntityOfPage'] = [
			'@id' => $this->context->canonical . Schema_IDs::WEBPAGE_HASH,
		];
	}

	// If this is a post and the author archives are enabled, set the author archive url as the author url.
	if ( $this->context->indexable->object_type === 'post' ) {
		if ( $this->helpers->options->get( 'disable-author' ) !== true ) {
			$data['url'] = $this->helpers->user->get_the_author_posts_url( $user_id );
		}
	}

	return $data;
}