Nothing here yet.
Nothing here yet.
No blogs yet.
Ionic has a great set of tools, but Angular is slow if you do not look out for the ngFor's, etc.. Pretty easy to set up, build, test, deploy and hard to maintain. NativeScript is really complicated to set up, but then is a breeze and have a Native device APIs. My next thing will be Xamarin, I think it's the best in terms of quality and support.
Basically there at least three approaches and you cannot figure out which will be your favorite before try them(it's a pity). But, I think one of the best is ToddMotto's style guide. Another favorite is Mot Cowley's angular folder structure . And do not forget that Angular team has it's own style guide . For me, the separate component, view, guard, directives, pipes approach is the best.
Hey, Avinash Dalvi You tagged #angular so if its Angular 1 you can use $rootScope. If you have access on the window object . In a bootstrap method you can save it in the window object. // INDEX.js const constants = { fruit: 'orange' , type: 'orange' }; window .myConstant = constants; // HOME.js let rootVar = window [ 'myConstant' ]; console .log(rootVar.fruit);
I managed to think out a solution. I really need jQuery to be able to create more complex DOM traversing with X-PATH, so i inject jQuery on the page li so: var script = document .createElement( 'script' ); script.src = "https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js" ; document .getElementsByTagName( 'head' )[ 0 ].appendChild(script);