Skip to content

Working with Functions

sameeri edited this page Apr 1, 2015 · 7 revisions

Saibaba Vinayakaya Namaha!


Function Properties

  • Code/Behavior
  • Object
  • Callable
  • First-class
  • Multipurpose

Function Definition

  • Function Declaration
  • Function Expression
    • Named
    • Unnamed (Anonymous)

Function Invocation

  • Regular
  • As a method on an object
  • Recursive(calling itself)
  • Immediately Executing
  • Call, Apply
  • Bind

Function as Data

  • Assignment
    • Variable
    • Object's property(method)
    • Array Element
  • Arguments
  • Return Value

Function Multipurpose Uses/Applications

  • Constructor
  • Stand-alone function
  • Higher Order function
  • Data
  • Object Method
  • Lambda

Function as a scope provider

  • Variable Object
  • Hoisting
  • Closures
  • Scope chain

Commonly used terms

  • Functor
  • Pure function
  • State-less function
  • Predicate
  • Comparator
  • Callback Function
  • Event Handler
  • IIFE
  • SIAF
  • Inner function
  • Recursive function

Clone this wiki locally