# Does OCaml ecosystem have CSS preprocessors?

**URL:** <https://discuss.ocaml.org/t/does-ocaml-ecosystem-have-css-preprocessors/2139>\
**Category:** Ecosystem\
**Tags:** frontend, css\
**Created:** [June 13, 2018, 5:01pm UTC](https://discuss.ocaml.org/t/does-ocaml-ecosystem-have-css-preprocessors/2139 "2018-06-13T17:01:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![egoholic](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/egoholic/32/574_2.png) [@egoholic](https://discuss.ocaml.org/u/egoholic)\
**Post date:** [June 13, 2018, 5:01pm UTC](https://discuss.ocaml.org/t/does-ocaml-ecosystem-have-css-preprocessors/2139/1 "2018-06-13T17:01:00Z")

</div>

Does OCaml’s ecosystem have CSS preprocessors except CCSS (cause I want to write CSS in OCaml)?

---

<div class="post-metadata">

**Author:** ![rgrinberg](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/rgrinberg/32/40_2.png) [@rgrinberg](https://discuss.ocaml.org/u/rgrinberg)\
**Post date:** [June 15, 2018, 6:32am UTC](https://discuss.ocaml.org/t/does-ocaml-ecosystem-have-css-preprocessors/2139/2 "2018-06-15T06:32:52Z")

</div>

I’m not familiar with anything, but it would be really nice if we had something like [https://github.com/slamdata/purescript-css](https://github.com/slamdata/purescript-css)

---

<div class="post-metadata">

**Author:** ![shinzui](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/shinzui/32/798_2.png) [@shinzui](https://discuss.ocaml.org/u/shinzui)\
**Post date:** [June 15, 2018, 1:18pm UTC](https://discuss.ocaml.org/t/does-ocaml-ecosystem-have-css-preprocessors/2139/3 "2018-06-15T13:18:56Z")

</div>

I’ve used [bs-css](https://github.com/SentiaAnalytics/bs-css) to write CSS in OCaml.

It allows you to write something like:

```ocaml
open CSS
let card = style
[
  display flexBox;
  flexDirection column;
  boxShadow ~y:(px 3) ~blur:(px 5) (rgba 0 0 0 0 0.3);
]
```
