Closed srid closed 5 years ago
How do you propose to solve this? Do we have a YAML library written in pure Haskell?
I haven't taken a look at how exactly YAML is being used in mmark, but at first glance I'd say by using a different library that is written in pure Haskell. This comes up: https://github.com/haskell-hvr/HsYAML
I’ll take a look.
Hmm, pure YAML implementation is good, but that one lacks Aeson compatibility and parse errors are plain String
s.
Time for a myaml
library then? :-)
Heh, would be good to have something like HsYAML
but with Megaparsec and Aeson-based ;)
I don't remember if I already asked you this, but would it be reasonable to make yaml
an optional dependency of mmark
(so that it can be used in GHCJS today)?
How will it work when yaml
is disabled? Should it just ignore YAML blocks then?
Yup that’s what I was thinking. Just ignore yaml blocks (or just extract them as raw text).
I think ignoring the blocks would be a better idea because that doesn't lead to a conditional API.
@srid If you still care about this, I put in a PR #61 which I have working in a WIP obelisk implementation of the 'realworld'/conduit demo app in this commit: https://github.com/qfpl/reflex-realworld-example/commit/e8eb77943a8d20ce946a2fed44b4bffae7c5b975
Implemented in #61.
Would you open for a PR to support GHCJS?
The
yaml
dependency doesn't compile on GHCJS.