Angularjs basic tutorial _ AngularJS

Source: Internet
Author: User
AngularJS is designed to overcome the shortcomings of HTML in building applications. HTML is a well-designed declarative language for static text display, but it seems weak to build WEB applications. So I did some work (you can also think it is a little trick) to let the browser do what I want. I haven't written anything for a long time. I don't know where to start writing anything. now I should write something technical first, angularjs-my brother called it "brother-in-law js"

1. Download

The code is as follows:

Official website: https://angularjs.org/
CDN:https://ajax.googleapis.com/ajax/libs/angularjs/1.3.0-beta.5/angular.min.js

2. Introduction 1. ng-app

The scope of angularjs is determined. you can use

The code is as follows:



...

For angularjs to render the entire page, you can also use

The code is as follows:



……


To render some of them.

2. ng-model

Ng-model: when your data model is changed, for example, ng-model = 'test', where the value of test is changed, the value of {test} will also change, that is, the value of test connected to ng-model will also change, as shown below:

The code is as follows:





Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.