Move all packages to a types directory

This commit is contained in:
Andy Hanson
2017-03-24 14:27:52 -07:00
parent f9869dc191
commit 354cec620d
13846 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
import fs = require('fs');
import BatchStream = require('batch-stream');
var batch = new BatchStream({ size : 5 });
var stream = fs.createReadStream('/etc/passwd');
stream
.pipe(batch)
.pipe(fs.createWriteStream('./test.out')); // deals with array input from pipe.

23
types/batch-stream/index.d.ts vendored Normal file
View File

@@ -0,0 +1,23 @@
// Type definitions for batch-stream 0.1.2
// Project: https://github.com/segmentio/batch-stream
// Definitions by: Nicholas Penree <http://github.com/drudge>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
/// <reference types="node" />
import stream = require('stream');
interface Options {
size?: number;
highWaterMark?: number;
}
declare class BatchStream extends stream.Transform {
size: number;
batch: any[];
constructor(options: Options);
}
export = BatchStream;

View File

@@ -0,0 +1,22 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": [
"es6"
],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": false,
"baseUrl": "../",
"typeRoots": [
"../"
],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"batch-stream-tests.ts"
]
}