shakespeare-sass: SASS support for Shakespeare and Yesod

[ bsd3, library, web ] [ Propose Tags ] [ Report a vulnerability ]

SASS support for Shakespeare and Yesod


[Skip to Readme]

Modules

[Index] [Quick Jump]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

Versions [RSS] 0.1.0.0, 0.1.0.2, 0.1.0.3, 0.1.4.1
Dependencies base (>=4 && <5), hsass (>=0.2.0 && <=0.8.0), shakespeare (>=2.0 && <2.1), template-haskell, yesod (>=1.4.1 && <=1.6.0), yesod-core (>=1.4.6 && <=1.6.14) [details]
License BSD-3-Clause
Author Filip Brcic
Maintainer brcha@yandex.com
Category Web
Home page https://github.com/brcha/shakespeare-sass#readme
Bug tracker https://github.com/brcha/shakespeare-sass/issues
Source repo head: git clone https://github.com/brcha/shakespeare-sass
Uploaded by brcha at 2019-09-18T13:01:34Z
Distributions
Reverse Dependencies 1 direct, 0 indirect [details]
Downloads 2209 total (10 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2019-09-18 [all 1 reports]

Readme for shakespeare-sass-0.1.4.1

[back to package description]

Shakespeare SASS

Build Status Hackage Hackage deps

About

Shakepeare SASS is a package to enable the usage of SASS language in the Yesod web framework.

Using Shakespeare SASS

Adding SASS support to your Yesod website is, actually, quite simple and straight-forward. After adding shakespeare-sass into your .cabal file (and stack.yaml if you are using stack), all you have to do is change your widgetFileSettings in Settings.hs from = def to = wfsSass ["sass_include/"]. And, of course, import Text.Shakespeare.Sass at the beginning of the file.

The argument for wfsSass function is a list of directories relative to the project root where you want your .sass or .scss include files stored. The main SASS files will still reside in your templates directory, as it is with the default setup with .lucius files. That way you get to keep your mixins separate from the templates and have a clear directory structure. Of course, you can always add your templates directory to sass search path and keep everything in templates dir.

Note about deployment with Keter

In case you are using Keter for deployment (and you should, it's a great tool), you should also add directories with your sass templates to the extraFiles: list in the config/keter.yaml file. Don't forget to put the ../ prefix, since keter.yaml's paths are relative to the config directory.