getSlotNamesFor
Overview
Get all matching prefixed slots for a given type and fieldName.
Signature
getSlotNamesFor(slots, prefixType, fieldName, exclude, checkExpanded, keepEmptySuffix)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| slots | object | yes | The slots object |
| prefixType | string | yes | e.g., 'field', 'widget', 'header' |
| fieldName | string | yes | e.g., 'foo' or 'foo__bar' |
| exclude | string[] | yes | List of slot names or suffixes to exclude. |
| checkExpanded | boolean | no | If true, expanded slots are also checked. |
| keepEmptySuffix | boolean | no | If true, empty suffixes are kept in the result. |
Returns
[string, string][]
- [outerName, innerName] slot pairs
Source
client/lib/utils/rendererSupport.js:35