Skip to main content
Module

x/rimbu/actor/mod.ts>SliceConfig.configure

Rimbu is a TypeScript library focused on immutable, performant, and type-safe collections and other tools.
Go to Latest
function SliceConfig.configure
import { SliceConfig } from "https://deno.land/x/rimbu@1.0.4/actor/mod.ts";
const { configure } = SliceConfig;

Returns a configured object that can be used to produce slices with the given configuration.

Parameters

config: { applyHandler: SliceConfig.ApplyHandler<C>; applyIncluder: SliceConfig.ApplyIncluder<C>; applyHandlerResult: SliceConfig.ApplyHandlerResult<C>; createAction: (sliceName: string, actionName: string) => C["_ACTION_CREATOR"]; }
  • the configuration for the slice creator.

Returns

{ create<S, LU extends SliceConfig.ActionDefinition<S, C>>(config: LU & { name?: string; initState: OptLazy<S>; includeActions?: (includer: SliceConfig.ActionIncluder<S, C>) => SliceConfig.ActionIncluderResult<S, C>; }): Slice<S, SliceConfig.SliceActions<LU["actions"], C>>; }