@luna-ui-com/if-context
v0.0.12
Published
#### install
Downloads
7
Readme
@luna-ui-com/data-segmentation
install
npm i --save @luna-ui-com/data-segmentation
Usage
import { computedSegment } from "@luna-ui-com/data-segmentation";
const x = {...} //fake object
const isSegment = computedSegment({
isPowerUser: true,
isExternalUser: false,
});
isSegment({
isPowerUser: x.isPowerUser(true),
isExternalUser: x.isExternalUser(false),
}) // Equal True;
isSegment({
isPowerUser: x.isPowerUser(true),
isExternalUser: x.isExternalUser(true),
}) // Equal False;
if(isSegment({
isPowerUser: x.isPowerUser(true),
isExternalUser: x.isExternalUser(false),
})) DO_SOMETHING();