Core Function
View Source on Trac ↗ wp_interactivity_state()
wp_interactivity_state( ?string $store_namespace = null, array $state = array() ) Gets and/or sets the initial state of an Interactivity API store for a
Parameters 1 required
| Name / Type | Description |
|---|---|
| $store_namespace string | The unique store namespace identifier. |
| array | $state Optional. The array that will be merged with the existing state for the specified store namespace. Required |
Return Value
(array)
array The state for the specified store namespace. This will be the updated state if a $state argument was
provided.
Function Information
Since Version
6.5.0
Source File
wp-includes/interactivity-api/interactivity-api.php
Advertisement