Search code examples
authenticationinterpolationyesodbrowserid

Yesod auth route to plugin page interpolation


Is there some value constructor that I can use to interpolate default url of BrowserID's plugin page in pattern @{AuthR <Cons>}?

Currently I'm using @{AuthR $ PluginR "browserid" []}


Update

Well, now BrowserId plugin exposes forwardUrl alias which could be used for that purpose (since v1.3.4, commit)

A bit of explanations:

I want to use interpolation to render url of default BrowserId auth plugin route where assertion check occurs: /auth/page/browserid.


Solution

  • That's the right thing to do right now. What most of the plugins do is provide a pre-baked Route Auth value which is exposed by the module so you don't have to come up with that yourself. We should probably do the same for BrowserId. Would you be able to send a pull request?