Skip to content

Instantly share code, notes, and snippets.

@startling
Created April 9, 2013 01:00
Show Gist options
  • Save startling/5342027 to your computer and use it in GitHub Desktop.
Save startling/5342027 to your computer and use it in GitHub Desktop.
import Sheets
import Control.Applicative
import Control.Monad.State
import Data.Text (Text)
import qualified Data.Text as T
import qualified Data.Text.IO as T
simple :: [T.Text] -> Table (State Int) Text
simple = Table [counter id, see]
table :: IO (Table (State Int) Text)
table = simple . T.lines <$> T.readFile "impedimenta.txt"
main :: IO ()
main = style >>= \css -> table
>>= flip evalState 0 . html css "out.html" . horizontal 50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment