concept modal in category ionic

This is an excerpt from Manning's book Ionic in Action: Hybrid Mobile Apps with Ionic and AngularJS.
The $destroy event fires when the current scope has been deleted from memory. Anything that exists in that scope is removed at the same time, but popovers and modals both create isolated scopes that persist. Because of this architecture, there isn’t an automatic way to remove the modal or popover from memory.
If you forget to do this in your app, it probably won’t cause your app to become very slow. How much of an impact it might have depends on the complexity and memory use of the popover or modal. It might not have a noticeable impact on most apps if it’s forgotten, but it’s best to remove them.
Throughout the chapter we’ll look at a number of Ionic’s features and components. The side menu will be the basis for your app navigation, and you’ll use just a single left menu that can appear to navigate around the app. You’ll use the action sheet component to provide users a list of options, such as to note a favorite location. Using a modal, you’ll display the next year’s chart of sunrise and sunset values. To make this chart perform better, you’ll use the collection repeat feature of the Ionic lists, which reduces memory for large lists by rendering only the necessary items.
Modals are used heavily in user interfaces today. A modal is a temporary view that’s layered above the current view. On websites, modals are often used to prompt a user to sign up for a newsletter or to force focus on a subset of content that darkens the rest of the content. If you’re following along using Git, you can check out the code for this step:
$ git checkout –f step8On a mobile device, a modal may be used in slightly different contexts, but the principles remain the same. The main draw of the modal is the fact that it can open above the current content, but be closed to return. Some example modal uses include showing a preview of a search result item without leaving the search result page, opening a modal with a list of additional search filters, or displaying an alert or notice for a weather event. You can see a modal in action in figure 6.9.
Modals are designed to overlay the entire app when the app is running on a smaller phone device. If the app runs on a larger tablet device, the modal will not actually fill the entire app, but will float in the middle. You can modify the exact size with CSS, but by default the size of the modal is a percentage of the size of the screen on tablets. This is important because it means that without some custom styling, the modal window size will vary from device to device.