F
findByProps
Finds a module exposing all of the given property names. Lazy unless { lazy: false } is passed: the search runs on first access.
function findByProps<K extends MetroLookupFirst<MetroPropName>, T extends MetroLookupArgs<string>>(first: K, ...rest: T): MetroPropertyRecordOrArray<[K, ...T[]], string>Finds a module exposing all of the given property names. Lazy unless { lazy: false } is passed: the search runs on first access.
Parameters
| Name | Type | Description |
|---|---|---|
| first | K | The first property name to search for. |
| ...rest | T | The other property names, optionally followed by options. |
Returns
MetroPropertyRecordOrArray<[K, ...T[]], string>The matched module (or matches, for a bulk/all search), typed from Discord's modules when the props are known.
function findByProps<T extends MetroLookupArgs<string>>(...args: T): MetroPropertyRecordOrArray<T, string>Finds a module exposing all of the given property names. Lazy unless { lazy: false } is passed: the search runs on first access.
Parameters
| Name | Type | Description |
|---|---|---|
| ...args | T |
Returns
MetroPropertyRecordOrArray<T, string>The matched module (or matches, for a bulk/all search), typed from Discord's modules when the props are known.