ngbp / ngbp

A sophisticated build management system for web apps (formerly ng-boilerplate). Created by @joshdmiller
http://bit.ly/ngBoilerplate
MIT License
3.92k stars 1.04k forks source link

Is there any predefined solution for a global configuration? #393

Open julkue opened 9 years ago

julkue commented 9 years ago

In previous projects without ngbp I've used requireJS which is similar to the modular architecture from AngularJS. I had a module "config" which I loaded as a dependency for each other module. Is there any predefined way to handle a global configuration in ngbp or should I continue loading the configuration as a module?

Thank you!

jeremy-albuixech commented 9 years ago

I believe NGBP is just a starting point for your AngularJs apps, the main goal being to start working with a basis of good practices and design patterns. It does not include any sort of configuration module, when I'm coding I tend to follow the Angular-styleguide recommendations (https://github.com/johnpapa/angular-styleguide#style-y128) which are, for configuration, to create a configuration file for each module like module1.config.js, placed side by side with the module entry point and which will hold all the constants used in the module.

julkue commented 9 years ago

Yea.. I found out that a few functions are missing in ngbp so I built my own boilerplate: http://github.com/julmot/jmBoilerplate