React_Term implements Registerable
Base class that handles react powered js files to output on taxonomy terms pages.
Interfaces, Classes and Traits
- Registerable
Table of Contents
- $file_name : string
- Name of the file that will be enqueued.
- $json_accessor : string
- The name of the constant that holds the json data for the frontend.
- $plugin : Licensed_Plugin
- Plugin instance.
- __construct() : mixed
- Get things started.
- assets() : void
- Enqueue the assets.
- created_term() : void
- Update the term metadata.
- register() : void
- Hook into WP.
- should_enqueue() : bool
- Determine if the asset should enqueue.
- is_edit_page() : bool
- Determine if we're viewing the edit page of a term.
Properties
$file_name
Name of the file that will be enqueued.
public
string
$file_name
Name only, without the extension.
$json_accessor
The name of the constant that holds the json data for the frontend.
public
string
$json_accessor
$plugin
Plugin instance.
public
Licensed_Plugin
$plugin
Methods
__construct()
Get things started.
public
__construct(Licensed_Plugin $plugin) : mixed
Parameters
- $plugin : Licensed_Plugin
Return values
mixed —assets()
Enqueue the assets.
public
assets() : void
Return values
void —created_term()
Update the term metadata.
public
abstract created_term(string $term_id, string $tt_id, string $taxonomy) : void
Parameters
- $term_id : string
- $tt_id : string
- $taxonomy : string
Return values
void —register()
Hook into WP.
public
register() : void
Return values
void —should_enqueue()
Determine if the asset should enqueue.
public
abstract should_enqueue() : bool
Return values
bool —is_edit_page()
Determine if we're viewing the edit page of a term.
protected
is_edit_page() : bool