I'd propose to give a following example of using Haquery in ghci, which is one of the common usages of fetching a website and parsing it.
import Haquery (select, parseHtml)
import Network.Wreq (get, responseBody)
import Control.Lens (^.)
import Data.Text (pack)
r <- get "http://nixos.org/channels/"
Prelude.concatMap (select (pack "a")) $ parseHtml $ pack $ show (r ^. responseBody)
Which motivates me to say that select should accept a list of Tags, since that's what parseHtml returns.
PS: I'm fairly new to Haskell ecosystem, so excuse my ignorance :)
I'd propose to give a following example of using Haquery in ghci, which is one of the common usages of fetching a website and parsing it.
Which motivates me to say that
selectshould accept a list of Tags, since that's whatparseHtmlreturns.PS: I'm fairly new to Haskell ecosystem, so excuse my ignorance :)