UNPKG

@types/dot

Version:
57 lines (44 loc) 1.38 kB
# Installation > `npm install --save @types/dot` # Summary This package contains type definitions for dot (https://github.com/olado/dot). # Details Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/dot. ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/dot/index.d.ts) ````ts export as namespace doT; /** Version number */ export const version: string; /** Template settings */ export let templateSettings: TemplateSettings; export type RenderFunction = (...args: any[]) => string; /** Compile template */ export function template(tmpl: string, c?: TemplateSettings, def?: {}): RenderFunction; /** For express */ export function compile(tmpl: string, def?: {}): RenderFunction; export interface TemplateSettings { evaluate: RegExp; interpolate: RegExp; encode: RegExp; use: RegExp; useParams: RegExp; define: RegExp; defineParams: RegExp; conditional: RegExp; iterate: RegExp; varname: string; strip: boolean; append: boolean; selfcontained: boolean; } declare global { interface String { encodeHTML(): string; } } ```` ### Additional Details * Last updated: Mon, 06 Nov 2023 22:41:05 GMT * Dependencies: none # Credits These definitions were written by [ZombieHunter](https://github.com/ZombieHunter).