Standardise format of the three "state" questions.#7046
Standardise format of the three "state" questions.#7046zpao merged 2 commits intofacebook:masterfrom
Conversation
The original format follows the template: > 1. x? if `x` then probably isn't state > 2. y? if `!y` then probably isn't state > 3. z? if `z` then it's not state This caused both me and a hallway tester to do a double take. The proposed reformulation allows the answers to follow the same template. In the same spirit, it uses the same contraction pattern in the last answer (`it's not state`-> `it isn't state`). This has the welcome side effect to make the lack of "probably" stand out more.
| 1. Is it passed in from a parent via props? If so, it probably isn't state. | ||
| 2. Does it change over time? If not, it probably isn't state. | ||
| 3. Can you compute it based on any other state or props in your component? If so, it's not state. | ||
| 2. Does it remain the same over time? If so, it probably isn't state. |
There was a problem hiding this comment.
"remain the same over time" feels a bit odd to me, though I can't put my finger on exactly why. I read it and I'm like "what does that mean?"
Perhaps: "Is it a constant value that never changes? If so, it probably isn't state."
There was a problem hiding this comment.
I wanted to avoid negatives in the question, but I see how that phrasing might sound clunky.
@jimfb Would you go with "Does it remain constant over time"?
There was a problem hiding this comment.
How about "Does it remain constant (immutable) over time? If so, it probably isn't state." I feel like "constant" is better than "remain the same" but is still a little vague.
There was a problem hiding this comment.
What about "does it stay constant over time"? The "stay" helps bringing home the idea I think.
At any rate, the "no-negatives" wasn't dogmatic. "Does it remain unchanged over time" is also fine for me. Let me know which one you prefer and I'll edit accordingly.
There was a problem hiding this comment.
Personally, I think "Does it remain unchanged over time" reads the best. I think I'd go with that one.
|
@cbrandolino updated the pull request. |
|
Looks good, thanks @cbrandolino! |
* Standardise format of the three "state" questions. The original format follows the template: > 1. x? if `x` then probably isn't state > 2. y? if `!y` then probably isn't state > 3. z? if `z` then it's not state This caused both me and a hallway tester to do a double take. The proposed reformulation allows the answers to follow the same template. In the same spirit, it uses the same contraction pattern in the last answer (`it's not state`-> `it isn't state`). This has the welcome side effect to make the lack of "probably" stand out more. * Update phrasing in thinking in reacr (cherry picked from commit 5bca377)
The original format follows the template:
This caused both me and a hallway tester to do a double take.
The proposed reformulation allows the answers to follow the same template.
In the same spirit, it uses the same contraction pattern in the last answer (
it's not state->it isn't state). This has the welcome side effect to make the lack of "probably" stand out more.