davidchambers / string-format

JavaScript string formatting inspired by Python’s `str.format()`

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Include type definition for TypeScript usage

jimsleon opened this issue · comments

TypeScript becomes popular these days, so it will be great if type definition is included in the npm page so that it could be used in TypeScript projects.

I'll happily accept a pull request for this, @jimsleon. :)

We just created a file string-format.d.ts under src

declare module 'string-format' {
const format: any;
export = format;
}

and used it as

import * as format from 'string-format';