What is a thunk?
JavaScript
Thunk
A thunk is a function that has everything already that it needs to do to give you some value back. You do not need to pass any arguments in, you simply call it and it will give you a value back.
JAVASCRIPT
1function add(x, y) {2 return x + y;3}45var thunk = function () {6 return add(10, 15); // 257};89thunk();