jashkenas--coffeescript/documentation/sections/prototypal_inheritance.md

256 B
Raw Blame History

Prototypal Inheritance

In addition to supporting ES2015 classes, CoffeeScript provides a shortcut for working with prototypes. The :: operator gives you quick access to an objects prototype:

codeFor('prototypes', '"one_two".dasherize()')