jaydata icon indicating copy to clipboard operation
jaydata copied to clipboard

$data.generatedContext

Open a2dude opened this issue 8 years ago • 0 comments

Using jaysvcutil with -m I get the following:

(function(mod) {
    stuff removed...

    mod($data.generatedContext || ($data.generatedContext = {}), $data); // Plain browser env
})(function(exports, $data) {

As $data is a singleton in the global context (correct?) how can I support multiple, ie distinct, models? Should model 1 set type and factory to $data.generatedContext.model1[ type / factory ] to distinguish these from model 2?

a2dude avatar May 05 '16 13:05 a2dude