imported 25 definitions from typescript-node-definitions

first batch: the easy pickings

- as per https://github.com/borisyankov/DefinitelyTyped/issues/115
- added DT headers (scraped creators from git history)
- added tests
- some modifications
- added CONTRIBUTORS.md for the substantial defs (>50 LOC)
This commit is contained in:
Bart van der Schoor
2014-04-22 22:09:35 +02:00
parent 033d3ae33e
commit 09f3d7a8dc
51 changed files with 3420 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
/// <reference path="swig.d.ts" />
import swig = require('swig');
var value: any;
var str: string;
var num: number;
var bool: boolean;
var opts: swig.Options = {
allowErrors: bool,
autoescape: bool,
cache: bool,
encoding: str,
filters: value,
root: str,
tags: value,
extensions: value,
tzOffset: num
};
swig.init(opts);
value = swig.compileFile(str);
value = swig.compile(str);
value = swig.compile(str, opts);
+24
View File
@@ -0,0 +1,24 @@
// Type definitions for swig
// Project: http://github.com/paularmstrong/swig
// Definitions by: Carlos Ballesteros Velasco <https://github.com/soywiz>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
// Imported from: https://github.com/soywiz/typescript-node-definitions/swig.d.ts
declare module "swig" {
export function init(options: Options): void;
export function compileFile(filepath: string): any;
export function compile(source: string, options?: Options): any;
export interface Options {
allowErrors?: boolean;
autoescape?: boolean;
cache?: boolean;
encoding?: string;
filters?: any;
root?: string;
tags?: any;
extensions?: any;
tzOffset?: number;
}
}