Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Callback functions

Learning Javascript and node.js, and am using callback functions without fully understanding them. Any recommendations for easily digestible content (treehouse or otherwise) that explains them in a simple and basic way?

Tutorial videos, fundamental drilling techniques, or good metaphors etc.

Thanks in advance!

3 Answers

Chris Shaw
Chris Shaw
26,676 Points

Hi Kathryn Lawhorn,

Have a read of the below articles, they should give you some valuable insight into callback functions.

Happy coding!

For me I did not completely understand it until I wrote my own function that used a callback. Chris' first link goes over creating such a function in vanilla JavaScript. I suggest trying to make a few other random little functions that also use callbacks to see if that helps your understanding! ♥