This course has been updated! We now recommend you take the Complete Intro to React, v8 course.

Check out a free preview of the full Building Web Apps (with React, Ampersand, ES6 and Webpack) course:
The "Canceling New Labels" Lesson is part of the full, Building Web Apps (with React, Ampersand, ES6 and Webpack) course featured in this preview video. Here's what you'd learn in this lesson:

If the user chooses to cancel the creation of a new label, the model object in memory will need to be destroyed. Henrik adds a conditional statement to the onCancelClick method to determine if the label is saved or if it should be destroyed.

Get Unlimited Access Now