[Part 2]AngularJS Initialization Demo with init & bind method

preview_player
Показать описание
AngularJS starts automatically when the web page has loaded.

The ng-app directive tells AngularJS that the div element is the "owner" of an AngularJS application.

The ng-model directive binds the value of the input field to the application variable name.

The ng-bind directive binds the innerHTML of the span element to the application variable name.

As you have already seen, AngularJS directives are HTML attributes with an ng prefix.

The ng-init directive initialize AngularJS application variables.
Рекомендации по теме