Save and Cancel Buttons

In this lesson, we’ll discuss the changes in the “Save” and “Cancel” buttons’ functionalities.

Setting the confirmedLeave property

We should also take care to allow clicking the “Save” button. However, we need to add the confirmation dialog when “Save” is clicked, because it triggers a router transition. Simply setting the confirmedLeave property will do:

Get hands-on with 1200+ tech skills courses.