三元表达式、箭头函数
来源:互联网 发布:mac可以用草图大师吗 编辑:程序博客网 时间:2024/05/16 09:50
<!DOCTYPE html><html lang="en"><head> <meta charset="UTF-8"> <title>Title</title> <script src="http://code.jquery.com/jquery-1.9.1.js"></script></head><body ><script>/* $(document).ready(function(){ alert('页面加载执行') });*/ //等同于 window.onload= ()=>{ alert(2)} // 箭头函数就是这么简单/* var a=1 if(a) { alert(a) } else { alert('不存在') } */ //等同于 a=1 a?alert(a):alert('不存在') //要习惯用三元表达式</script></body></html>
0 0
- 三元表达式、箭头函数
- TypeScript入门-9.函数箭头表达式
- JavaScript 箭头函数(Lambda表达式)
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 三元表达式
- 匿名函数(Lambda表达式)与箭头函数
- 箭头函数
- 箭头函数
- 箭头函数
- 箭头函数
- Handler,Looper,Message,HandlerMessage,Thread关系及区别
- 关于快排函数
- TypeError: Error #1034: Type Coercion failed: cannot convert mx.managers::HistoryManagerImpl@f22eee1
- OpenCV python学习笔记(五)
- 21. DNS 配置和端口检测
- 三元表达式、箭头函数
- How to install tftp-server on Fedora 25 workstation
- 使用Mybatis-Generator自动生成Dao、Model、Mapping相关文件(转)
- 22. 使用 awk / grep / head / tail 命令进行文本 / 日志分析
- 什么是crm
- 23. CURL 常用命令
- 虚拟机
- node之path模块
- 从控制台获取输入的字符串