mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-12-03 11:41:44 +00:00
Update types for findup-sync
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
import findup = require('findup-sync');
|
||||
|
||||
let str: string;
|
||||
|
||||
str = findup('foo');
|
||||
str = findup(['foo', 'bar']);
|
||||
|
||||
str = findup('foo', {
|
||||
matchBase: true,
|
||||
});
|
||||
|
||||
str = findup('foo', {
|
||||
cwd: 'c:\\',
|
||||
});
|
||||
|
||||
str = findup('{a,b}*.txt');
|
||||
str = findup('{a,b}*.txt', { cwd: '/some/path', nocase: true });
|
||||
Vendored
+22
@@ -0,0 +1,22 @@
|
||||
// Type definitions for findup-sync 2.0
|
||||
// Project: https://github.com/cowboy/node-findup-sync
|
||||
// Definitions by: Bart van der Schoor <https://github.com/Bartvds>
|
||||
// Nathan Brown <https://github.com/ngbrown>
|
||||
// BendingBender <https://github.com/BendingBender>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.2
|
||||
|
||||
import micromatch = require('micromatch');
|
||||
|
||||
export = findupSync;
|
||||
|
||||
declare function findupSync(
|
||||
patternOrPatterns: string[] | string,
|
||||
micromatchOptions?: findupSync.Options
|
||||
): string;
|
||||
|
||||
declare namespace findupSync {
|
||||
interface Options extends micromatch.Options {
|
||||
cwd?: string;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": false,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"findup-sync-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"extends": "dtslint/dt.json"
|
||||
}
|
||||
Reference in New Issue
Block a user