We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 06c5def commit 873d7dcCopy full SHA for 873d7dc
example/Gzip.js
@@ -0,0 +1,7 @@
1
+/* global exports */
2
+/* global require */
3
+"use strict";
4
+
5
+// module Gzip
6
7
+exports.gzip = require('zlib').createGzip;
example/Gzip.purs
@@ -0,0 +1,20 @@
+module Gzip where
+import Prelude
+import Node.Stream
+import Node.Stream.StdIO
8
+import Control.Monad.Eff
9
+import Control.Monad.Eff.Console
10
11
+foreign import data GZIP :: !
12
13
+foreign import gzip :: forall eff. Eff (gzip :: GZIP | eff) (Duplex (gzip :: GZIP | eff))
14
15
+foreign import
16
17
+main = do
18
+ z <- gzip
19
+ stdin `pipe` z
20
+ z `pipe` stdout
0 commit comments