Go to file
Misko Hevery b4db73d0bf feat: ngIf now supports else; saves condition to local var
NgIf syntax has been extended to support else clause to display template
when the condition is false. In addition the condition value can now
be stored in local variable, for later reuse. This is especially useful
when used with the `async` pipe.

Example:

```
<div *ngIf="userObservable | async; else loading; let user">
  Hello {{user.last}}, {{user.first}}!
</div>
<template #loading>Waiting...</template>
```

closes #13061
closes #13297
2016-12-09 11:19:08 -08:00
.github docs(gh): try to improve the issue template (#11891) 2016-09-30 16:40:56 -07:00
docs docs(public_api): fix missing backtick 2016-10-07 17:23:08 -07:00
modules feat: ngIf now supports else; saves condition to local var 2016-12-09 11:19:08 -08:00
scripts feat(compiler): read and write `.ngsummary.json` files 2016-12-01 14:49:52 -08:00
tools feat: ngIf now supports else; saves condition to local var 2016-12-09 11:19:08 -08:00
.bowerrc chore(dgeni): clean up legacy typings bundle creation 2015-10-29 21:19:59 +00:00
.clang-format feat(tooling): Add a .clang-format for automated JavaScript formatting. 2015-04-02 08:44:34 -07:00
.editorconfig chore(.editorconfig): include markdown config 2015-01-27 00:14:48 -08:00
.gitattributes chore: force lf EOL for ts files (#11143) 2016-08-29 12:41:58 -07:00
.gitignore chore(git): cleanup .gitignore 2016-09-02 15:58:46 -07:00
.nvmrc chore(node): allow current node version 2016-09-19 16:24:31 -07:00
.travis.yml chore(ci): re-enable browserstack tests in ci 2016-10-20 10:01:51 -07:00
CHANGELOG.md docs(changelog): fix a typo (#13298) 2016-12-08 11:23:57 -08:00
COMMITTER.md chore(docs): update the merge process docs 2015-12-23 02:32:02 +00:00
CONTRIBUTING.md docs(contributing): fix styleguide link and typos (#13198) 2016-12-05 10:25:20 -08:00
DEVELOPER.md docs(developer): add anchor to source code formatting (#13199) 2016-12-05 10:27:20 -08:00
LICENSE Update change from Apache to MIT license 2016-01-08 13:41:58 -08:00
NAMING.md refactor(ngProbe): rename to ng.probe 2015-08-31 21:32:10 +00:00
README.md docs(readme): remove incorrect download count badge 2016-10-05 11:37:28 -07:00
SAVED_REPLIES.md docs(saved-replies): order the replies as shown in github (#12153) 2016-10-07 13:52:18 -07:00
TOOLS.md chore(docs): remove sentences for dart (#10781) 2016-08-16 19:38:49 -07:00
TRIAGE_AND_LABELS.md doc: update triage owners for language service and router (#13325) 2016-12-08 15:42:34 -08:00
bower.json refactor(benchmarks): make tree benchmark work again 2016-08-29 12:42:57 -07:00
browser-providers.conf.js refactor: add license header to JS files & format files (#12081) 2016-10-04 20:39:20 -07:00
build.sh fix(language-service): update to use `CompilerHost` from compiler-cli (#13189) 2016-12-02 14:34:16 -08:00
circle.yml fix(ci): pin version of npm on CircleCI (#12954) 2016-11-17 17:27:51 -08:00
gulpfile.js chore(lint): extend linting to all modules and tools 2016-10-31 14:24:27 -07:00
karma-js.conf.js feat(language-service): add services to support editors (#12987) 2016-11-22 09:10:23 -08:00
npm-shrinkwrap.clean.json build(tslint): enable no-inner-declarations (#13316) 2016-12-08 13:46:08 -08:00
npm-shrinkwrap.json build(tslint): enable no-inner-declarations (#13316) 2016-12-08 13:46:08 -08:00
npm-shrinkwrap.readme.md chore(lint): replace gulp check-task with tslint no-jasmine-focus rule 2016-10-28 15:53:15 -07:00
package.json build(tslint): enable no-inner-declarations (#13316) 2016-12-08 13:46:08 -08:00
protractor-e2e.conf.js refactor: add license header to JS files & format files (#12081) 2016-10-04 20:39:20 -07:00
protractor-examples-e2e.conf.js refactor: add license header to JS files & format files (#12081) 2016-10-04 20:39:20 -07:00
protractor-perf.conf.js refactor: add license header to JS files & format files (#12081) 2016-10-04 20:39:20 -07:00
publish-packages.sh fix: display framework version on bootstrapped component (#13252) 2016-12-06 16:21:07 -08:00
shims_for_IE.js Revert "refactor: add license header to JS files & format files (#12035)" 2016-10-04 14:06:41 -07:00
test-main.js refactor: add license header to JS files & format files (#12081) 2016-10-04 20:39:20 -07:00
test.sh refactor(compiler): remove unneeded fields from metadata 2016-11-28 15:19:23 -08:00
tslint.json build(tslint): enable no-inner-declarations (#13316) 2016-12-08 13:46:08 -08:00

README.md

Build Status CircleCI Join the chat at https://gitter.im/angular/angular Issue Stats Issue Stats npm version

Sauce Test Status
Safari (7+), iOS (7+), Edge (14) and IE mobile (11) are tested on BrowserStack.

Angular

Angular is a development platform for building mobile and desktop web applications. This is the repository for Angular 2 Typescript/JavaScript (JS).

Angular2 for Dart can be found at dart-lang/angular2.

Quickstart

Get started in 5 minutes.

Want to help?

Want to file a bug, contribute some code, or improve documentation? Excellent! Read up on our guidelines for contributing and then check out one of our issues in the hotlist: community-help.