Skip to content

Commit 62ef3f3

Browse files
committed
Add minLength note to README
1 parent 2809ac6 commit 62ef3f3

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

README.md

+5-4
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,12 @@ Here's a quick screen recording of the expected result:
5353
- (Don't forget, you can use an NPM script to generate the scaffolding for you!)
5454
- This component should render a `<form>` tag, including a label and a text input.
5555
- The text input should be controlled by React state.
56-
- **The user's input should be converted to ALL UPPERCASE.** No lower-case letters allowed.
57-
- The input should have a minimum and maximum length of 5.
5856
- When the form is submitted:
59-
- The entered value should be logged to the console (for now)
57+
- The entered value should be logged to the console (for now).
6058
- The input should be reset to an empty string.
59+
- **The user's input should be converted to ALL UPPERCASE.** No lower-case letters allowed.
60+
- The input should have a minimum and maximum length of 5.
61+
- **NOTE:** The `minLength` validator is a bit funky; you may wish to use the `pattern` attribute instead. This is discussed in more detail on the [Solution page](https://courses.joshwcomeau.com/joy-of-react/project-wordle/06-solution#an-alternative-to-minlength).
6162

6263
## Exercise 2: Keeping track of guesses
6364

@@ -291,7 +292,7 @@ In our clone, we aren't picking a new word every day, we're picking a new word w
291292

292293
Update the game so that it can be restarted. Add a "Restart game" button to the banner shown when the user wins or loses.
293294

294-
_HINT:_ This will require moving the `answer` into state. You'll want to do the random word selection inside a callback function, the secondary way to initialize state described here: https://courses.joshwcomeau.com/joy-of-react/02-state/03-use-state#initial-value
295+
This will require moving the `answer` into state. You may wish to revisit the lesson on “Lazy Initialization” from Module 2!
295296

296297
**Acceptance Criteria:**
297298

0 commit comments

Comments
 (0)