javascript - Defining functions on scope from a remote controller on the same server -
i working on project, framework renders data defined in layouts (screens) in format of jsons. example, write ,
{ name : "first name", row : "1" , type: "text box" }
it render text box label "first name".
i have central service root scope of entire framwork. requirement -
user/developer write own controller , html on same server outside of framework code.
to controller pass
$scope
, define new methods , provide html need render.this html use functions on scope can either f/w or controller.
i have explored -
angular ajax - http://tutorials.jenkov.com/angularjs/ajax.html
angoose - https://github.com/tjworks/angoose
i not sure if design correct. need in different way ? or there way achieve have designed.
thanks in advance.
if 1 stumbles on question , how solved
our application build structure maven related. placed these custom services , html on same server , wrote automation program include these files based on inputs in properties files.
once inclusion out of way , angular injector did rest of adding service dynamically , html 'ng-include'-ed.
for explore angular based solution please check out -
https://github.com/ifyio/angularjs-lazy-loading-with-requirejs
Comments
Post a Comment