Web-development – How to structure an App one back-end & Multiples front-end

front-endproject-structureweb-development

I have a big challenge to solve where I have some ideas but I don't know what would be the best solution.

Basically I have to develop an application where I have to develop a back-end(web service) and Multiples front-end. The core for all the applications is going to be the same, same requests and functionality.

What is going to change is the css, some wording and display in some cases different data(but not that different)

so far I have been thinking in do a main application for the front-end(ex. using bootstrap) where adding a css file to change the style and a js file with rules to display different data and for the different wording.

But how I can really do it? how can I prevent extra work in the future to do changes in each website(front-end), how can I include the rules properly. Also I dont want to create 1 front-end and add conditions(it's a bad practice and I'll have a lot of problem in the future)

Note: I'll use c# for the web service and angular 2 for the front-end (the technologies are mandatory because my company no way to change it). Probably angular 2 provide me a good way to do what I am thinking.

Best Answer

If you're working on one platform that containing one backend and multiple front-end, I think that's easy using RESTful.

For example, if the first front-end application is for ADMINS and second front-end application is for simple USERS, you can differentiate by (login function for example):

front-end 1 call : /admins/login

front-end 2 call : /users/login

Each end point'll call a controller that can treate each case