The network may be unreliable and loading data may take time. Thus it is important to give the user some feedback about what's going on as fast as possible. In this lesson we learn how to leverage the else block of the *ngIf directive to show a simple loading indicator.

    <div *ngIf="buttonClicked">
<div *ngIf="person$ | async as person; else personLoading">
Name: {{ person.name }} <br />
Twitter: {{ person.twitter }}
</div>
<ng-template #personLoading>
Loading person...
</ng-template>
</div>

最新文章

  1. RDIFramework.NET平台代码生成器V3.1版本全新发布-更新于2016-10-29(提供下载)
  2. 9.1 js基础总结2
  3. iOS 阶段学习第八天笔记(指针)
  4. paper 75:使用MATLAB的神经网络工具箱创建神经网络
  5. C++:概述
  6. Javascript高级程序设计读书笔记(第二章)
  7. Android ImageView(scaleType属性)图片按比例缩放
  8. winform在鼠标操作时要判断是否按下Ctrl键
  9. PAT乙级1065 map
  10. (转)Spring Boot(十二):Spring Boot 如何测试打包部署
  11. spark获取时间
  12. SpringMVC @RequestBody的使用
  13. 第16月第6天 vs2005 lseek directdraw
  14. linux每日命令(17):which命令
  15. java web 方面
  16. img 标签
  17. Python中对矩阵的洗牌操作
  18. Java web中WEB-INF目录理解
  19. MongoDB删除文档
  20. spring.net 在demo中的分析

热门文章

  1. mysql 编码错误修改
  2. Linux编译ffmpeg
  3. HDU——T 4738 Caocao&#39;s Bridges
  4. 14.NPM 常用命令
  5. 用Bandwidth Controller实现局域网带宽控制
  6. 杠杆(leverage)就是支付保证金借钱进行交易,以小博大
  7. BZOJ1492: [NOI2007]货币兑换Cash(CDQ分治,斜率优化动态规划)
  8. Redmine安装
  9. amazeui学习笔记一(开始使用3)--兼容性列表compatibility
  10. SD卡与tf卡引脚转换