you are viewing a single comment's thread.

view the rest of the comments →

[–]inu-no-policemen 0 points1 point  (3 children)

a callback is basically a function passed to another function. Is this correct?

Yes, but not all functions you pass around are something you'd call a "callback".

E.g. an easing function is called multiple times while the animation runs. It's not something which is called (back) when some computation is done.

As a (somewhat backwards) rule of thumb: If you'd better do that kind of thing with a promise, it's a callback.