Mongodb connection from ionic hybrid app on phone


#1

I am trying to uderstand the way this works. Please let me know if my understanding is correct:

  1. Ionic app runs on mobile, and connects to remote node js
  2. node js on remote server connects to remote mongodb
  3. data is returned back to ionic app through node interface

#2

Yes. That’s a pretty typical setup.


#3

@wedgybo
Apart from Ionic/ Angular, Node and MongoDB, what else is required for the set up?
Understand there’s a need for a seperate API for ndoe to communicate to the mobile.


#4

You use node to create the API for your app using some like the express or HAPI framework. Then you just use Angulars $http or $resource components to interact with the API you design.

You can skip the node step these day by using service like parse.com or firebase.com There’s quite a few of these backend as a services popping up that lets you just focus on writing the application