From React Quickly by Azat Mardan
This article covers how to capture text input and input via other form elements like input, textarea, and option. Working with them is paramount to web development because they allow our applications to receive data (e.g. text) and actions (e.g. clicks) from users.
In this article we’re going to build a lock and key system. Each lock has its own unique key. The lock holds some secret data and only returns the data if accessed with the correct key. We’ll then build a game where we generate three locks and give the player only one key and one chance to unlock a prize!