0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

JavaScriptのコールバック関数

Posted at

今ProgateでJavaScriptやってるんですけど、コールバック関数の
直接定義みたいなので、左の事前に定義した関数は理解できるんですけど、右の直接引数の中で定義してる方がいまいち理解に苦しみます

PXL_20210623_070933961.jpg

左のやつはこんな感じのイメージで理解してるんですけど
PXL_20210623_070245559.jpg

右のやつは引数としてcallbackにconsole.logが代入されても、
ちゃんと呼び出されない感覚があるのであります。

どんなイメージなら理解出来そうですか?

0
0
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?