浏览代码

add readme

Aurélien Richez 4 年之前
父节点
当前提交
41bdc35a31
共有 1 个文件被更改,包括 34 次插入0 次删除
  1. 34 0
      readme.md

+ 34 - 0
readme.md

@@ -0,0 +1,34 @@
+# $PROJECT_NAME
+
+## What is $PROJECT_NAME ?
+
+$PROJECT_NAME is a user friendly, type safe, wrapper around node streams. The API is a simplified 
+version of scala's [akka stream](TODO).
+
+Node stream API has a few flaws in my view. It is tedious, verbose, error prone, badly typed...
+Yet, it does work. So stream-helper wraps node stream and provides a user friendly API on top of it,
+along with some useful functional helpers (filter, map...). This allows stream-helper to easily 
+integrate with existing node streams, while providing simplercorrecly typed and fluent API.
+
+## What it is not
+
+ - $PROJECT_NAME is not a port of akka stream. It does not aim to perfectly reproduce akka stream 
+ API.
+ - $PROJECT_NAME is not a complete stream implementation. Implementing streams correctly with
+ backpressure is tricky, so $PROJECT_NAME uses the nodejs stream api.
+
+## Getting started
+
+```
+  Source.fromReadableBuilder
+```
+
+The API is organised around three interfaces :
+
+ TODO : lazy evaluation
+
+### Source
+
+This is the starting point of your stream. Think of it as a `Readable` in node streams. 
+
+As a matter of fact, you can build a source from a `Readable` with `Source.fromReadableBuilder`.