Articles for February 2015

Learn how to use $scopes properly in AngularJS | ThinkingMedia

Here is a tutorial for the 7 best practices for working with $scopes in AngularJS.

Source: www.thinkingmedia.ca

#1 – Keep the $rootScope clean of variables

This rule is based on the idea that the $rootScope is a global variable and falls under the best practice that Global Variables Are Bad. Adding variables to the$rootScope will result in source code that is difficult to maintain. The usage of those variables will be scattered across JavaScript files, directives, controllers and templates. It will also make it difficult to unit test source code and do refactoring.

See on Scoop.itAngular.org.il

Token-Based Authentication With AngularJS & NodeJS – Tuts+ Code Tutorial

Authentication is one of the most important parts of any web application. In this tutorial, we’ll be discussing token-based authentication systems and how they differ from traditional login systems. | Difficulty: Intermediate; Length: Long; Tags: AngularJS, Node.js, Heroku, MongoDB, JavaScript, Authentication, Web Applications

Source: code.tutsplus.com

See on Scoop.itAngular.org.il

Futuristic Routing in Angular

A few months ago the Angular team announced that there’s going to be a completely new router component in one of the future Angular releases. In fact, the new router is being implemented for Angular 2.0 and was planned to be back ported for the 1.3 release. Unfortunately, it turned out that it takes a bit more effort to make the same powerful router available for both development branches based on the same code base, so the team decided to postpone the back port of the new router to the next big

Source: blog.thoughtram.io

See on Scoop.itAngular.org.il