r/web_programming • • Aug 05 '16

Deciding on an appropriate stack

Hey Reddit! We are a small team wanting to build a web app that will eventually be a mobile app using Ionic. With this in mind, it seems suitable to have Angular as the front-end framework. For the back-end, I suggested to the team that we build a RESTful API with Rails (or Laravel, or Slim). However, other team members have suggested we use Node.js/Express.js. Does anyone care to share any insights regarding the possible paths that we can take? Our main areas of concern are with authentication, handling somewhat complex database relationships, and implementing instant chat (web sockets?). Thanks in advance. ~B

3 Upvotes

3 comments sorted by

1

u/captainTigger Mod Aug 06 '16

so many technologies so close to my heart :P

an angular web app and an ionic hybrid web app are 2 very different things, you may be able to reuse some code but if you try to shoehorn a web app into a hybrid mobile app you'll have a whole world of problems, and the same is true of the reversal of that progression.

slim is a very good lightweight php restful api framework, i've used it many time with angular for both web app and hybrid mobile app and it works well. node is a good tool but its db integration is alot more temperamental, but its really good for web socket stuff, much better than any implementation of php websockets i've come across, my suggested stack would be slim for your data and business logic layer, node websockets for your RTC functionality( look at socket.io, and to build the web app and hybrid phone app seperately, it will mean quite a bit more work, but it will save you a world of headaches in the end, thats speaking from experience. they can use the same backend though. as far as authentication look into json web tokens, and unless you really need it all in house consider using oauth and login with google/facebook/twitter/github/other or something as it gives you the added benifit of having your users authenticated to those services from the context of your app if you need/want any integration with any services.

1

u/rayanche Aug 06 '16

Hey, thanks for the reply! Guess I wasn't clear in my post, our web app will certainly be separate from our hybrid mobile app. Our team is familiar with Slim, and if we go that route we would probably use Slim and the Eloquent ORM. Interesting that you bring up Sockets.io, I've heard not-so-great things about it, making be a bit hesitant on that end :/

1

u/jrj996 Aug 12 '16

If you're looking to create an MVP, I'd say go Rails to start with and if Rails becomes too bloated then either try to optimize better or move onto a new framework while maintaining the same json format for your requests