1.0.0 • Published 1 year ago
@jtorm/if-method v1.0.0
jTorm If Method
If / Else method.
Install
npm install @jtorm/if-methodProperties
| Option | Type | Required | Description |
|---|---|---|---|
d | data | true | Data. |
v | regex | false | Test the data within the if scope using a regexp or boolean. |
el | string | false | Element to check if exists. |
to | string | false | Type check, check if array, string, number, etc for example. |
Example
body->append {
->if {
d: component;
->ui {
component: component;
}
->else {
->ui {
component: "list.default";
}
}
}
}