O'Reilly logo

AngularJS Directives Cookbook by Fernando Monteiro

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How to scale an AngularJS project to use reusable directives

An important key is the consistency of your code; there are many ways to do it right.

Another important key is the principle of DRY (Don't Repeat Yourself). DRY code is easier to work with and will help you build applications that are more maintainable.

Pay close attention to naming conventions, this is another very important point. Using intuitive and short names makes your code easier to work and makes it easier to keep a pattern.

No pattern is absolutely failsafe or bullet proof, but you must choose which best fits your application and use it from start to finish.

Large-scale applications often grow at a steady pace from their beginning until you reach an intermediate state; however, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required