You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Renato Alves edited this page Aug 10, 2026
·
1 revision
Conditions
The condition parameter determines under which condition(s) the asset should load.
include
string|array
Requires that all conditions be truthy in order for the asset to load.
The include property is implied if the condition parameter is a string or array of strings; otherwise the condition parameter must contain the include property.
include_any
string|array
Allows for any condition to be truthy, instead of requiring that all conditions be.
exclude
string|array
Requires that all conditions be falsey in order for the asset to load. This is skipped if neither include nor include_any are truthy.
Custom Conditions
There are a few default conditions included out-of-the-box:
Name
Condition
'global'
true
'single'
is_single()
'search'
is_search()
Use the am_asset_conditions filter to add or replace conditions.