You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I encountered your project and from what I saw, you really help getting routing done in purescript quite easily.
I'm fairly new to Purescript, but I still understood your documentation.
The only problem I see is that there is no complete example.
And to test my routes, I did a small function that I can call from the purescript REPL:
testRoute::String->String
testRoute r = case (match maybeMyRoute r) ofLeft err -> err
Right (Just (Admin)) ->"page admin"Right (Just (Domain dom)) ->"page domain: " <> dom
Right (Just (Home)) ->"page home"Right (Nothing) ->"page nothing?"
The only problem I have is that I don't know how to make the "main" function to make it all work.
I'm pretty sure this could be done in a couple of lines, but I have no idea where to start.
Thanks, and have a good day!
The text was updated successfully, but these errors were encountered:
As a Purescript beginner, but experienced Haskeller, the parser combinator approach based on Match is straightforward, but I'm completely stumped by comments such as
"Returns an effect which will remove the listener."
Hello everyone,
I encountered your project and from what I saw, you really help getting routing done in purescript quite easily.
I'm fairly new to Purescript, but I still understood your documentation.
The only problem I see is that there is no complete example.
Here is what I did as an example:
And to test my routes, I did a small function that I can call from the purescript REPL:
The only problem I have is that I don't know how to make the "main" function to make it all work.
I'm pretty sure this could be done in a couple of lines, but I have no idea where to start.
Thanks, and have a good day!
The text was updated successfully, but these errors were encountered: