-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ElmWithRoc #196
ElmWithRoc #196
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @rasheedmhd -- this will be a useful example for people looking to build a backend for Elm apps. 😄 I've left some comments for you.
examples/ElmWithRoc/webserver.roc
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like this example should include more routes, or interesting things to integrate/work with Elm.
Some ideas ... we could have the webserver include a JSON endpoint or two? Maybe an example authentication flow? Maybe do some CRUD on a sqlite database?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's good to have a minimal example, we can add a more complex one later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree we can add another more complex example later, but I do think we should consider more for the roc side here. My concern is that the current implementation may also confuse someone who isn't familiar with roc because the routing and servers-side parts are left out.
We can keep the elm minimal, because the reader is likely familiar with Elm, and add a little to the roc web-server -- maybe demo using roc-json or something.
I can contribute some ideas if that helps.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, good idea, roc-json is indeed what you would use, even for a simple webapp.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've made issue #198 for this
I apologize for not making this clear, but I'm nearly finished with my review and changes. Please hold off on making changes until my commit is in. Edit: Done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @rasheedmhd!
You're welcome and THANKS too |
An example for creating Elm applications that uses the roc basic-webserver