0.16.1 • Published 5 months ago
@allbin/entity-logic v0.16.1
@allbin/entity-logic
Entity filter executor
How to use
import {
EntityLogic,
Entity,
EntitySchema,
Filter,
FilterCondition
} from '@allbin/entity-logic'
const schema: EntitySchema = {
/* ... */
};
const entities: Entity = [ /* ... */ ];
const hasValue: FilterCondition = {
field: 'user.1',
propType: 'string',
operator: 'known',
}
const matchesWildcardString: FilterCondition = {
field: 'user.1',
propType: 'string',
operator: 'matches',
value: 'wild*cards'
};
const filter: Filter = [
hasValue,
matchesWildcardString,
];
const logic = EntityLogic(schema); // need one of these per schema
const result = logic.execute(entities, filter);
0.16.1
5 months ago
0.11.0
9 months ago
0.12.0
9 months ago
0.10.2
9 months ago
0.13.0
9 months ago
0.14.0
9 months ago
0.15.0
9 months ago
0.16.0
8 months ago
0.10.1
1 year ago
0.10.0
1 year ago
0.9.2
1 year ago
0.9.1
1 year ago
0.9.0
2 years ago
0.8.1
2 years ago
0.8.0
2 years ago
0.6.3
2 years ago
0.6.4
2 years ago
0.7.0
2 years ago
0.6.2
2 years ago
0.5.0
2 years ago
0.4.0
2 years ago
0.6.1
2 years ago
0.5.1
2 years ago
0.3.2
3 years ago
0.3.1
3 years ago
0.3.0
3 years ago
0.1.0
3 years ago
0.1.2
3 years ago
0.2.0
3 years ago
0.1.4
3 years ago
0.0.5
3 years ago
0.0.6
3 years ago
0.0.4
3 years ago
0.0.3
3 years ago
0.0.2
3 years ago
0.0.1
3 years ago