Summary
In this chapter, we learned about Angular services and how to correctly isolate the business rule from our applications in a simple and reusable way, as well as how Angular services use the singleton pattern for memory and performance optimization.
We worked with and studied Angular’s dependency injection mechanism and noticed how important it is to be able to organize and reuse services between components and other services. We also learned how to use the inject
function for Angular services as an alternative to dependency injection via Angular’s constructor.
Finally, we worked with one of the main uses of services, communication with the backend, and in this chapter, we began to explore the integration of our frontend applications with the backend.
In the next chapter, we will study the best practices for using forms, the main way that our users enter information into our systems.