Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/jacobbubu/pull-stream-types


https://github.com/jacobbubu/pull-stream-types

Last synced: 14 days ago
JSON representation

Awesome Lists containing this project

README

        

# @jacobbubu/pull-stream-types

[![Build Status](https://travis-ci.org/jacobbubu/pull-stream-types.svg)](https://travis-ci.org/jacobbubu/pull-stream-types)
[![npm](https://img.shields.io/npm/v/@jacobbubu/pull-stream-types.svg)](https://www.npmjs.com/package/@jacobbubu/pull-stream-types/)

> Yet another [pull-stream](https://github.com/pull-stream/pull-stream) typescript declaration file.

## Intro.

Although [Michael de Wit](https://github.com/mjwwit) has provided a typescript declaration file for [pull-stream](https://github.com/pull-stream/pull-stream), in order to facilitate some type-wise modifications, I still extract the original one out and use it independently.

## Usage

```bash
npm install pull-stream -S
npm install @jacobbubu/pull-stream-types -D
```

Then add a module definition into your `compilerOptions` in `tsconfig.json`. That may look like:

```json
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"pull-stream": ["node_modules/@jacobbubu/pull-stream-types"]
}
}
}
```

It works for `tsc`, `ts-node` and `ts-node-dev`.

## Test

A test file(`test/pull-stream-test.ts`) has been provided to verify the correctness of the declaration file.

You can `npm run build:watch` for debugging.