UNPKG

grafast

Version:

Cutting edge GraphQL planning and execution engine

11 lines 836 B
import type { ListCapableStep, Step } from "../step.js"; import type { __ItemStep } from "./__item.js"; import type { ItemsStep, StepRepresentingList } from "./connection.js"; import type { __ListTransformStep, ListTransformItemPlanCallback } from "./listTransform.js"; export type FilterPlanMemo = unknown[]; /** * Filters a list plan to only include entries for which the `filterCallback` * plan results in a truthy value. */ export declare function filter<TListStep extends StepRepresentingList<any>, TItemStep extends Step<boolean>>(listStep: TListStep, filterCallback: ListTransformItemPlanCallback<ItemsStep<TListStep>, TItemStep>): __ListTransformStep<TListStep, TItemStep, FilterPlanMemo, TListStep extends ListCapableStep<any, any> ? ReturnType<TListStep["listItem"]> : __ItemStep<any>>; //# sourceMappingURL=filter.d.ts.map