Download this file
| 1 | {-# LANGUAGE TemplateHaskell #-} |
| 2 | |
| 3 | -- | Files compiled into the binary. The two TodoMVC stylesheets come |
| 4 | -- straight from the bakeoff's @shared/@ directory, so they're served byte |
| 5 | -- for byte. |
| 6 | module Todo.Assets |
| 7 | ( baseCss |
| 8 | , indexCss |
| 9 | , appCss |
| 10 | , appJs |
| 11 | ) where |
| 12 | |
| 13 | import Data.ByteString (ByteString) |
| 14 | import Data.FileEmbed (embedFile, makeRelativeToProject) |
| 15 | |
| 16 | baseCss, indexCss, appCss, appJs :: ByteString |
| 17 | baseCss = $(makeRelativeToProject "../../shared/base.css" >>= embedFile) |
| 18 | indexCss = $(makeRelativeToProject "../../shared/index.css" >>= embedFile) |
| 19 | appCss = $(makeRelativeToProject "static/app.css" >>= embedFile) |
| 20 | appJs = $(makeRelativeToProject "static/app.js" >>= embedFile) |
| 21 | |