/js-state-encapsulation

Examples of state encapsulation in Javascript

Primary LanguageJavaScript

Javascript state encapsulation (without classes!)

Build Status

An example of how you can encapsulate state (and even make it private) with just plain functions and object literals. No prototypes, new, or this!

There are also tests for everything (i.e. 100% coverage, just for fun).