What's the difference between a function property and a function method?

I was working on this lesson, and I wasn’t sure what the difference is between a function property and method. Might seem obvious, but after reading the docs I couldn’t find a concrete answer.

Any help is appreciated!

You can play around in the console to see what the “properties” are that are being referenced.

Screen Shot 2021-04-28 at 2.12.30 PM

To understand this better it helps to read up a little about object-oriented programming.
Methods are basically functions that belong to objects. So in this case a function method is a function of a function (kind of like function composition in math).

The takeaway is that when you define a function, it doesn’t just magically hold itself together. When you define arguments for that functions, they become essentially a part of it (reflected in Function.prototype.arguments).

This lesson seems to be analyzing functions themselves from one step back the usual layer you may first encounter them in.

2 Likes