UNPKG

flooent

Version:

Fluent interface to provide an expressive syntax for common manipulations.

32 lines (31 loc) 1.12 kB
import Arrayable from "./collections/Arrayable"; import Stringable from "./collections/Stringable"; import Mappable from "./collections/Mappable"; import { MapValue } from './types'; /** * Create a flooent string. You have access to [everything from the native String object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String). */ declare function string(value: string): Stringable; declare namespace string { var macro: (key: string, callback: Function) => Function; } declare const given: { string: typeof string; array: { <T>(value: T[]): Arrayable<T>; macro(key: string, callback: Function): Function; /** * Executes callback for number of base values' times and returns a flooent array with the result of each iteration. */ sized: any; }; map: { <K, V>(value: MapValue<K, V>): Mappable<K, V>; macro(key: string, callback: Function): Function; /** * Create a map from an object */ fromObject: any; }; }; export { Stringable, Arrayable, Mappable, given };