The Performance Difference Between ng-bind and {{}}

Interpolation is one of the first things newcomers to Angular learn.
You can’t get around writing your first Angular “Hello, World” without some sort …
Continue reading “The Performance Difference Between ng-bind and {{}}”

Single Page Apps with AngularJS Routing and Templating – Hell’s Kitchen

Single Page Apps with #AngularJS Routing and Templating

  • Let’s add the module and controller to our HTML so that Angular knows how to bootstrap our application.
  • Since we have our module and controller set up and we know that Angular is working properly, we will start working on using this layout to show the different pages.
  • is an Angular directive that will include the template of the current route (/home, /about, or /contact) in the main layout file.
  • Since we are making a single page application and we don’t want any page refreshes, we’ll use Angular’s routing capabilities.
  • This way, each part of our application will use its own view and Angular controller.

Single page apps are becoming increasingly popular. Sites that mimic the single page app behavior are able to provide the feel of a phone/tablet application. Angular helps to create applications like this easily.
Continue reading “Single Page Apps with AngularJS Routing and Templating – Hell’s Kitchen”

How to build Minesweeper using Angular 2 and Immutable.js

How to build Minesweeper using #Angular 2 and Immutable.js:  #javascript

  • If every mutation returns a new object, dirty checking can use a blazingly fast strict equality check:

    Although performance is fine without Immutable.js in a small application like Minesweeper, it is a great way to explore it nonetheless for when we need to build larger Angular 2 apps in the future.

  • So if we have a game with 16 x 16 tiles, the data structure will look like this:

    where each tile is an immutable map of properties:

    The Angular 2 application can be broken down in 4 components:

    The actual game logic originates entirely from Christian’s React.js example and is stored in and .

  • Let’s start by having a look at the component that is instantiated when the Angular 2 application is bootstrapped:

    In the method of the component, we make sure a new game is created when the component is initialized.

  • The minesweeper component is where most magic happens so let’s have a look at the entire code first:

    Because we passed the object to the component in the component, we have to make sure the component accepts it.

  • This is done by creating a decorated class property:

    Basically this tells Angular to accept what is passed in through the property and store it as a property in the component controller.

This is the first in a series of articles on Angular 2. If you want me to send you a quick note when a new article is available, just leave your email at the bottom of the article or follow me on Twitter.
Continue reading “How to build Minesweeper using Angular 2 and Immutable.js”

The Recipe for Angular 2 in a Java EE Environment: Frontend 2

  • This is the fourth article in our “The Recipe for Angular 2 in a Java EE Environment” series, with a more detailed description of the Frontend of the Angular2 and JavaEE Project.
  • It follows my third article about Angular 2 and Java EE that gave a detailed overview of the Frontend infrastructure of the Car Rental Project.
  • In this article about the Angular UI, we’ll go over the HTTP Service with its Types, the Detailview with its Validations, and 2 Tests, which are shown.
  • Line 23: sets the Value of the Input Parameter of the Component as the value of the Formcontrol.
  • Angular provides a flexible Validation infrastructure that can be used to write Form Validations that validate values dependent on each other.

We continue our look at creating frontend code in Angular using a Java EE environment. We’ll go over HTTP Services, Detailview and validations, and run 2 tests.
Continue reading “The Recipe for Angular 2 in a Java EE Environment: Frontend 2”

AngularJS, Angular and Angular v4

Recommended post 💥 “#AngularJS, #Angular and Angular v4 by @Foxandxss #javaScript
”

  • The old and new Angular products need names that are fixed and independent of the version number.
  • With semantic versioning, you can tell if a new release is an easy install, with no breaking changes, simply by looking at the version number.
  • The downside is that breaking changes are inevitable and, therefore, new releases of Angular are bound to have version numbers like , , , etc.
  • Semantic Versioning (SemVer) is a convention that dictates how the version number changes for each new release of a library.
  • A breaking change means that upgrading to the new version of the library might cause your application to behave in an unexpected way that contradicts previously documented behavior or fail outright.

Angular tips blog
Continue reading “AngularJS, Angular and Angular v4”

Top 8 Resources to Explore Angular 4 – Hacker Noon

  • Top 8 Resources to Explore Angular 4Angular version 4 is out!In Dec, 8, Igor Minar announced that Angular 3 will be skipped.
  • He also introduced the tentative scheduling of the versions according to the semantic versioning.
  • The due date of Angular 4 release was Mar, 22.
  • In a delay of one day, the final version is available for all of us.As days past, the community begun discussing and discovering the new features.
  • It’s the best time to explore the new version.In this article we will look over the prime, qualitative and valuable resources.

In Dec, 8, Igor Minar announced that Angular 3 will be skipped. He also introduced the tentative scheduling of the versions according to the semantic versioning. The due date of Angular 4 release was…
Continue reading “Top 8 Resources to Explore Angular 4 – Hacker Noon”