JavaScript replicated model (M of MVC) library