LessonAbout 6 minLesson languageEnglishதமிழ் (Tamil)हिन्दी (Hindi)മലയാളം (Malayalam)తెలుగు (Telugu)ಕನ್ನಡ (Kannada)বাংলা (Bengali)मराठी (Marathi)ગુજરાતી (Gujarati)ਪੰਜਾਬੀ (Punjabi)Chapter 4 · Lesson 4 of 504. Updating from the value beforeGive the set function a function, and React passes it the latest value: the safe way to update from the value before.