Why are routes useful? Instead of filling a single view with more code than needed, routes let us map URLs to self-contained controllers and templates. Furthermore, now that the app has URLs, users can easily bookmark and share the app’s pages.
What can we generalize so far?
- Directives are a way to make standalone UI components, like
- Services are a way to make standalone communication logic, like
forecastwhich fetches weather data from a server
- Routes are a way to manage apps containing more views.