getData()

Function of @saij/wp-app-framework.

import { getData } from '@saij/wp-app-framework';
function getData(key: string): DataValue

A value of the view data of your theme or plugin, set in PHP with ViewData::set().

ParameterTypeDescription
keystringThe key of the value.

Returns DataValue: The value; an unknown key throws an error that names the known keys.