Files
DefinitelyTyped/minimatch/minimatch-tests.ts
Rogier Schouten af6197ad37 Bugfix in minimatch.d.ts
From README.md:  the exported function returns a boolean not a void.

var minimatch = require("minimatch")
minimatch("bar.foo", "*.foo") // true!
2014-11-14 11:28:52 +01:00

20 lines
379 B
TypeScript

/// <reference path="./minimatch.d.ts" />
import mm = require("minimatch");
var pattern = "**/*.ts";
var options = {
debug: true
};
var m = new mm.Minimatch(pattern, options);
var r = m.makeRe();
var f = ["test.ts"];
mm.match(f, pattern, options);
mm.filter('foo')('bar');
var s: string = "hello";
var b: boolean = mm(s, pattern, options);
var b: boolean = mm(s, pattern);