How to connect a Node.js server to React Native? - ios

I am creating a React Native app that needs a backend, and I only want to create a backend in Node.js (express.js).
How should I host/deploy this server so that it can interact with a React Native app?
From research, I have seen people simply deploy the node.js server to a web hosting service (like Heroku) then Fetch to that url in the react native app. My only concern is whether this entirely safe for a production app, as JWTs solve this problem but not exactly sure how to implement JSON Web Tokens into the React Native App.
Another way I have seen people do this is to add a server folder in the root of their react native project. I'm not sure exactly how this would work though because each app download would have a different local server attached.
Any help is appreciated. Thanks!

Related

How to generate .ipa file for React Native app that will communicate to a server-side database configuration like MongoDb?

Im newbie to React Native. I am trying to create a native react ios application.
However, if I need to build and ciruculate the app the database will most probably be a db such as MongoDb on a server.
My question is - How do I build the react native app to include server-side database credentials and connection URLs so that the ios application generated can be deployed on any mobile app using itunes to test?
I did look at the documentation available at: https://facebook.github.io/react-native/. However, for a newbie this documentation is a little complex from where I am at. If someone could give me enough explanations on how to get this done - would be very grateful.

Access a Qlikview dashboard on an iOS app

I have a Qlikview dashboard that I need to present and I've created a site that loads the Qlikview server onto the browser and runs it from there.
I now need to create an iOS app that does this. But the requirement is that the dashboard shouldn't open on the browser. The server should be loaded and run from the app itself. Is there any way to do this?
PS, I'm completely new to iOS App development and any help will be appreciated.
Yes. While saving it as a shortcut and opening it in the browser would be simple, using Apache Cordova is the best way to develop a smartphone app with HTML5/CSS/JavaScript. From the website:
When using the Cordova APIs, an app can be built without any native
code (Java, Objective-C, etc) from the app developer. Instead, web
technologies are used, and they are hosted in the app itself locally
(generally not on a remote http server).
And to make things better, it's open source.

React Native Server Configuration

guys! I'm a student iOS developer and new to the GREAT technique React Native.
My Question is:
if it is necessary for us to develop our React Native server with the help of Node.js? Can the server just return a static javascript file or bundle file to the client?
if so, does it mean that every time user enters THE React Native page(contains RCT controller or view), the App do not have to fetch the javascript file or bundle file from server? (Since if these files are unchanged in server, App should not download them for saving phone data/flow)
if so, could we use some Tag & Cache technique to solve this data saving problem?

Container application that rules all the modules

I got a new project from the client, it's about enterprise app. My question is, is it possible to create an app is a container application that rules/hold all the modules?
What I mean is the container application is the native app itself but the modules can be native or hybrid. Below is the sample screenshot of the app.
Is it possible?
Yes, Its possible to do. Try to utilise native components as many places as possible. Apple will not reject your application.

Build an iOS app & Node.js API simultaneously

I'm building an iOS app that communicates to a Node.js API I'm also building. Locally, everything is ok, I've structured my iOS code in a way that I only declare the API base URL in one place (ie. 192.168.0.3:5000 - local).
However, you can imagine where I'm going with this.
Once I deploy the API to Heroku, what's the best way for me to manage the iOS side of things in regard to: 1. testing locally with the local API, 2. deploying the iOS app to the app store (ie. how do I tell it to use a different API URL?)
Any advice would be great on setting up a sane development environment for this...
In your XCode project, configure the "debug" version to use the local api and the "release" version to use the web api.

Resources