Displaying a local notification using the local notification plugin
When you are developing mobile applications, your app might want to notify the user about something. If the information is coming from the backend, we use push notifications. But, if the information is generated by the app, locally on the device, we can use a local notification for that.
This recipe is intended to help you understand how local notifications work.
When you open the app, you will see the following page.

You can input anything in the input box and then click on SHOW NOTIFICATION
. You can also schedule a notification to show later. This is what a notification looks like in the notification area:

Getting ready
You should have a physical device ready in order to test local notifications.
How to do it...
Here are the instructions:
- Create a blank Ionic app (for example,
Notifications
) andcd
to that folder, as shown here:
$ ionic start Notifications blank$ cd Notifications
- Install the local notification plugin and Ionic native...