Posts

Showing posts with the label javascript

Common AngularJS Directives for Designers

Image
AngularJS is not only for UI developers, but also for UI designers. In fact, the separation of concerns and readability that AngularJS brings enable smooth collaboration between designers and developers. Here are some common directives that designers will encounter in AngularJS.

AngularJS and Strongly Typed Views

Image
AngularJS is a powerful templating MVC Javascript framework developed by Google. In this post, we will be talking about how to use AngularJS with ASP.NET MVC, particularly with strongly-typed views.

Scope Inheritance in AngularJS

Image
Scopes in AngularJS use prototypical inheritance. When a child scope tries to access a variable, it first looks for that variable in its own scope. If it doesn't find any, it looks for it in the parent scope, and so on until the $rootScope is reached. This post will illustrate this concept of inheritance in AngularJS.

Javascript: Truthy and Falsy Values

Image
I used to wonder what this Javascript code fragment means:

AngularJS: Using ng-repeat

Image
AngularJS is the Javascript MVC framework developed by Google. In this post we will build a simple application using AngularJS. If you aren't familiar with it, you might want to read my introduction to AngularJS first. This post will introduce the concept of controllers and the app will display a simple list of items (persons) to the view. In this application I will be using AngularJS 1.0.6 which is the latest stable version as of this writing. For the CSS, I am using Twitter bootstrap. Setting up the Files First off, here's the barebones html file as well as what it looks like when run:

Introduction to AngularJS

Image
If you've been reading about javascript frameworks then you're probably seen AngularJS. AngularJS is a javascript framework developed by Google. It supports a MVC pattern and handles two-way data binding between the model and the view. Aside from two-way data binding, it also has support for declaring new html syntax, validation, routing, and more. In this post we will talk about the data binding capability. Setting Up the Site First off, we need to have a reference to the AngularJS file, which you can download from here . In this example I downloaded the Uncompressed build of the Stable branch (1.0.6).