Angular.js Demo

angular.js is a popular MVW (Model-View-Whatever) framework. On the angular.js front page, scroll down to The Basics to see an overview of angular.js features.

This analysis is on GitHub.
angular.js information.


Angular.js Introduction

This page shows two of angular.js most popular applications. First, you get the nav-bar on top almost for free. The four tabs it accesses are part of a single page. This is pure JavaScript and you always stay inside this one page (even though the url bar of your browser updates). Second, the standard hello world example for frameworks like angular.js is tested below. The simplepi example that is also included here (in the other tabs) makes use of angular's data-binding. When a status signal is received from the Databench backend, the callback function simply assigns the new estimate of π to a variable of an angular controller, say pi. In the html file, the value is shown in an angular variable placeholder [[pi]].

Live Demo of Data Binding

Here is the standard code and right below is the live demo.

What you just typed: {{chapter}}

Simplepi π = {{pi}}

This little demo uses two random numbers r1 and r2 and then does a comparison r1^2 + r2^2 < 1.0 to figure out whether the generated point is inside the first quadrant of the unit circle.

Log Messages