Created
February 15, 2014 08:39
-
-
Save tatac1/9016280 to your computer and use it in GitHub Desktop.
tagstream and http-conduit combination
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE OverloadedStrings #-} | |
import qualified Data.Conduit.Binary as CB | |
import qualified Data.Conduit.List as CL | |
import qualified Text.HTML.TagStream.ByteString as TS | |
import Data.Conduit | |
import Network.HTTP.Conduit | |
main :: IO () | |
main = do | |
res <- simpleHttp "http://vul.jp/" | |
CB.sourceLbs res $= TS.tokenStream $$ CL.mapM_ print |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment