UNPKG

node-sitefile

Version:

Bootstrap Express webserver for misc. resources using Sitefile

26 lines (15 loc) 455 B
define 'sf-v0/module', [], -> moduleKeywords = ['extended', 'included'] class Module constructor: -> @extend: (obj) -> for key, value of obj when key not in moduleKeywords @[key] = value obj.extended?.apply(@) this @include: (obj) -> for key, value of obj when key not in moduleKeywords # Assign properties to the prototype @::[key] = value obj.included?.apply(@) this