当前位置:网站首页>箭头函数与普通函数的区别
箭头函数与普通函数的区别
2022-08-03 08:15:00 【大鸡腿最好吃】
1,写法不同
2,箭头函数没有自己的prototype原型对象,所以不能用作于构造函数
3,this指向不同
在普通函数中,this总是指向调用它的对象或者,如果用作构造函数,它指向创建的对象实例;
箭头函数没有自己的this,它的this始终指向父级上下文
4,箭头函数全都是匿名函数:普通函数可以有匿名函数,也可以有具名函数
边栏推荐
猜你喜欢

HCIP实验(06)

mysql服务器上的mysql这个实例中表的介绍

requests库

Docker starts mysql

Evaluate: A detailed introduction to the introduction of huggingface evaluation indicator module

熊市中预言机,牛市中的战斗机,藏宝计划起飞,坐稳扶好!

二进制日志过期时间设置expire_logs_days

【TPC-DS】DF的SQL(Data Maintenance部分)

Using pipreqs export requirements needed for the project. TXT (rather than the whole environment)

HCIP练习03(重发布)
随机推荐
ArcEngine (2) loading the map document
Mysql的in和exists用法区别
wordpress: 裁剪您的图片时发生错误
day12---接口和协议
ArcEngine (5) use the ICommand interface to achieve zoom in and zoom out
mysql服务器上的mysql这个实例中表的介绍
2022下半年软考「高项&集成」复习计划ta来喽~
ArcEngine(三)通过MapControl控件实现放大缩小全图漫游
流行和声基础大笔记
uni-app 顶部选项卡吸附效果 demo(整理)
实时目标检测新高地之#YOLOv7#更快更强的目标检测器
ArcEngine (4) Use of MapControl_OnMouseDown
The use of the database table structure document generation tool screw
Laya中关于摄像机跟随人物移动或者点击人物碰撞器触发事件的Demo
QT中线程调用GUI主线程控件的问题
unity的game界面里有canvas的线框?如何隐藏掉?
Docker启动mysql
MySQL数据库————数据库与vs的连接
mysql5.7服务器The innodb_system data file 'ibdata1' must be writable导致无法启动服务器
vs 2022无法安装 vc_runtimeMinmum_x86错误