mardi 31 juillet 2018

Integrating REST APIs within an Angular 6 Application

I am working creating a new Angular 6 application. The back-end for the application is Spring. I am expected to consume the backend REST APIs at the frontend. Please advice on the configuration required to achieve the same with in the Angular Application. Below are few changes that I can think of to be made at the frontend:

  • Importing the HttpClientModule with in the app.module.ts

  • Configure the environment.ts & environment.prod.ts files with the apiurl information

  • Create a rest api service to call various end point

Can anyone suggest on the right steps for the REST API consumption starting from scratch. Are there any configurations required in package.json or any other files ?

Please advice !




Aucun commentaire:

Enregistrer un commentaire