export types of content-type

This commit is contained in:
vvakame
2016-10-27 14:23:26 +09:00
parent 11f0445ae2
commit 3fdc528f73
2 changed files with 5 additions and 3 deletions
+2
View File
@@ -15,3 +15,5 @@ obj = contentType.parse(res);
var str: string = contentType.format({type: 'image/svg+xml'});
var media: contentType.MediaType;
contentType.format(media);
+3 -3
View File
@@ -3,10 +3,10 @@
// Definitions by: Hiroki Horiuchi <https://github.com/horiuchi>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
declare var x: ContentType.StaticFunctions;
export = x;
declare var ct: ct.StaticFunctions;
export = ct;
declare namespace ContentType {
declare namespace ct {
interface StaticFunctions {
parse(string: string): MediaType;
parse(req: { headers: any; }): MediaType;