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

I can't find some course about return(Javascript).

maybe i skipped:) can you help to find it?

2 Answers

since everything in javascript is an object.

Return just returns the function as an object.

Well primitives are not really objects. They are immutable...but JS creates wrappers objects for these primitives with methods and properties

But yes JS treats Functions as objects. Also we should mention that JS objects are not the same as objects in other oop languages