Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#プログラマ の脳が #コード を理解する仕組みってなんなの? チュートリアルのコードをダウンサイズして理解したい。( #React Introduction の例 ) #1391

Open
YumaInaura opened this issue Apr 24, 2019 · 0 comments

Comments

@YumaInaura
Copy link
Owner

Ref

Introducing JSX – React

Codepen

  • Codepenでコードをしばらく眺める
  • さっぱり分からずに固まる
  • ドキュメントに戻って読んだりする

A Pen by yumainaura

image

呼吸とかする

スタバの抹茶のティーラテをゆっくり飲む

熟成

  • コードの前で立ち止まるのは良くないというが、僕の場合は立ち止まる。
  • こんな簡単そうなコードでも立ち止まるので、自分の頭が相当悪いのだろうと、誰にもせかされていないのに焦ってくる。
  • 5分ぐらいゆっくりしていると、問題意識が立ち上がる。「どこがネックなの?」と。

コードの首を捕まえる

elementを

image

render してるだけじゃん!

image

elementを

image

render してるだけじゃん!

image

elementを

image

render してるだけじゃん!

image

このコードの並び順おかしくね? 分かりづらくない? と思って並び替える

image
image

もっと簡単にできるっしょ?と思って、引数やらなにやらを削っていく

image

ダウンサイズ!

分かってきた気がするぞ。

image

ちゃんと動いてるしね!

image

A Pen by yumainaura

コードが分からなかったら Hello world ぐらいまでダウンサイズ

とか、わりと良い方法かもしれない。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant