2

This is more that i don't know the terminology to Google to get the answer i need

example console.log()

where log is a sub function of console, what is the name/syntax of this sort of function?

  • See this-: http://stackoverflow.com/questions/164397/javascript-how-do-i-print-a-message-to-the-error-console – suspectus Mar 19 '13 at 11:31
  • @suspectus — The question is about the terminology given to functions that are values of properties, not about how to use `console.log`. – Quentin Mar 19 '13 at 11:40
  • got it thanks for all the help guys –  Mar 19 '13 at 11:44

1 Answers1

3

Functions that are properties of an object, and called in the context of that object are usually known as methods.

The EMCAScript (being "standard" JavaScript) specification has the following definition:

method

function that is the value of a property

Quentin
  • 914,110
  • 126
  • 1,211
  • 1,335