Type Definitions
Condition
A condition whether or not to match dependency.
- If the value is a
string
, resolves dependency with the same key. - If the value is a
RegExp
, resolves dependency with the key matching the regular expression. - If the value is a function, use it as a predicator against the key.
- If the value is
true
, resolves all. - If the value is
false
ornull
, resolves none. - If the value is an array of conditions, resolves any dependencies matching at least one condition. (i.e. logical OR)
- Source:
Type:
-
string
|RegExp
|conditionCallback
|boolean
|null
|Array.<Condition>
conditionCallback(key) → {boolean}
- Source:
Parameters:
Name | Type | Description |
---|---|---|
key |
string
|
The dependency's key. |
Returns:
- Type:
-
boolean
If the dependency should be resolved or not.