UNPKG

cerializr

Version:

(de)serialization made easy with ES7/Typescript annotations (decorators)

33 lines (30 loc) 1.03 kB
import { InstantiationMethod } from "./interfaces"; /** * Use one of the provided function or use your own custom function. * * No function provided will result to an unchanged string property. * * @example```js import { SetSerializeKeyTransform, CamelCase } from "cerializr"; SetSerializeKeyTransform(CamelCase);``` * * @param fn */ export declare function SetSerializeKeyTransform(fn: (str: string) => string): void; /** * Use one of the provided function or use your own custom function. * * No function provided will result to an unchanged string property. * * @example```js import { SetDeserializeKeyTransform, CamelCase } from "cerializr"; SetDeserializeKeyTransform(CamelCase);``` * * @param fn */ export declare function SetDeserializeKeyTransform(fn: (str: string) => string): void; /** * Change the default InstantiationMethod * @param instantiationMethod */ export declare function SetDefaultInstantiationMethod(instantiationMethod: InstantiationMethod | null): void;