I have that self-hosted RESTful messaging service with authorization, SSL and more good stuff that goes with it. Now, I would like to consume that service, so I need an UI. Usually (for cross-platforms sake) I tend to develop ASP.NET MVC web application, but this time I'm not sure how to proceed.
However, I have some ideas:
If there are two decoupled applications - a web application and a REST service - there will have to be CORS enabled on the client.
If there is a web application that somehow uses some proxy (forwarder?) to get to the REST service, I don't need CORS. But I don't know how exactly that should be done in MVC.
Another thing - I would really prefer this being decoupled, so I don't want a third option to be stuffing both things into one sack.
I am a bit disappointed with what google says on the topic. There should obviously be more information, or I don't know how to look for it.
My questions are:
- Should I go with choice #1 or #2?
- About choice #2, is that practical and is there a best practice solution?
- Is there a third choice I'm missing here?