This post shows how to use yesod directly with blaze-html,but following this post ghc complains that:
No instance for (ToWidget App (t0 -> H.Html))
arising from a use of ‘toWidget’
In the expression: toWidget
In a stmt of a 'do' block: toWidget $ \ render -> do { H.p "" }
In the second argument of ‘($)’, namely
‘do { toWidget $ \ render -> do { ... } }’
I checked source of the required yesod.pure module,but found there's no such instance for Towidget..
Are you including the package yesod-core
and the module Yesod.Core
?
That's where the ToWidget
class is defined.
I used Hayoo to find where ToWidget
was defined.