diff --git a/types/isstream/index.d.ts b/types/isstream/index.d.ts index b3d581e781..2dd8731df1 100644 --- a/types/isstream/index.d.ts +++ b/types/isstream/index.d.ts @@ -1,19 +1,39 @@ // Type definitions for isstream 0.1 // Project: https://github.com/rvagg/isstream -// Definitions by: Claas Ahlrichs +// Definitions by: My Self // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped -/// - export = isstream; -declare function isstream(obj: any): boolean; +declare function isstream(obj: any): any; declare namespace isstream { - function isDuplex(obj: any): boolean; + const prototype: { + }; - function isReadable(obj: any): boolean; + function isDuplex(obj: any): any; + + function isReadable(obj: any): any; + + function isWritable(obj: any): any; + + namespace isDuplex { + const prototype: { + }; + + } + + namespace isReadable { + const prototype: { + }; + + } + + namespace isWritable { + const prototype: { + }; + + } - function isWritable(obj: any): boolean; } diff --git a/types/isstream/isstream-tests.ts b/types/isstream/isstream-tests.ts index 107f1d46eb..e69de29bb2 100644 --- a/types/isstream/isstream-tests.ts +++ b/types/isstream/isstream-tests.ts @@ -1,37 +0,0 @@ -import isStream, {isReadable, isWritable, isDuplex} from 'isstream'; -import * as Stream from 'stream'; - -isStream(new Stream()) // true - -isStream({}) // false - -isStream(new Stream.Readable()) // true -isStream(new Stream.Writable()) // true -isStream(new Stream.Duplex()) // true -isStream(new Stream.Transform()) // true -isStream(new Stream.PassThrough()) // true - - - - -isReadable(new Stream()) // false -isWritable(new Stream()) // false -isDuplex(new Stream()) // false - -isReadable(new Stream.Readable()) // true -isReadable(new Stream.Writable()) // false -isReadable(new Stream.Duplex()) // true -isReadable(new Stream.Transform()) // true -isReadable(new Stream.PassThrough()) // true - -isWritable(new Stream.Readable()) // false -isWritable(new Stream.Writable()) // true -isWritable(new Stream.Duplex()) // true -isWritable(new Stream.Transform()) // true -isWritable(new Stream.PassThrough()) // true - -isDuplex(new Stream.Readable()) // false -isDuplex(new Stream.Writable()) // false -isDuplex(new Stream.Duplex()) // true -isDuplex(new Stream.Transform()) // true -isDuplex(new Stream.PassThrough()) // true \ No newline at end of file diff --git a/types/isstream/tsconfig.json b/types/isstream/tsconfig.json index 223c0a8c00..ddea72dd3e 100644 --- a/types/isstream/tsconfig.json +++ b/types/isstream/tsconfig.json @@ -7,15 +7,13 @@ "noImplicitAny": true, "noImplicitThis": true, "strictNullChecks": true, - "strictFunctionTypes": true, "baseUrl": "../", "typeRoots": [ "../" ], "types": [], "noEmit": true, - "forceConsistentCasingInFileNames": true, - "esModuleInterop": true + "forceConsistentCasingInFileNames": true }, "files": [ "index.d.ts",