Tutorial: Develop a Mobile App With Ionic and Spring Boot

Tutorial: Develop a Mobile App With Ionic and Spring Boot

This tutorial will show you how to build a Spring Boot API and an Ionic app, and then how to deploy the finished product to your iOS or Android-based mobile device.

Dinesh jakhar

Is there any video tutorial for this blog?

Matt Raible

I did a presentation at GeeCON 2017 where I develop this example on stage. You can find the recording on YouTube.

Varun L

Thanks for the excellent tutorial. It is really helpful.
What I am unable to understand is, how is the spring boot server able to accept a request from ionic-beer ui client when the app is deployed on a mobile device as we still have
@CrossOrigin(origins = {“http://localhost:8100”,“http://localhost:8080”}) . We are not specifying the host and port of the mobile device where the request is originating or not using a wildcard character allowing request from any domain. Correct me if I am wrong.
Thanks again.
V

Matt Raible

When you’re coming from a mobile device, CORS does not apply as far as I know. Ionic will send an origin header of “file://“, and your server will let that origin pass through. At least that’s how I understand it. I was confused by this too when I encountered it last year. https://github.com/ionic-te…

Varun L

Thanks Matt for your response. That really helped understand how to resolve the CORS issue… Also the blog post was very informative.