官术网_书友最值得收藏!

Arrow functions - the modern way

Even if arrow functions pretty much work as the other functions, there are some important differences with usual functions. These functions can implicitly return a value, the value of this is not bound, and there is no arguments object. Let's go over these three points.

There are some extra differences: arrow functions cannot be used as constructors, they do not have a prototype property, and they cannot be used as generators because they don't allow the yield keyword. For more details on these points, see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions#No_binding_of_this.

主站蜘蛛池模板: 保靖县| 邵武市| 垣曲县| 太湖县| 丹寨县| 耒阳市| 安徽省| 宣化县| 乐至县| 高淳县| 綦江县| 石台县| 财经| 平塘县| 永康市| 宜宾市| 登封市| 庆安县| 察隅县| 额济纳旗| 那坡县| 邢台县| 胶南市| 杂多县| 龙游县| 板桥市| 鸡东县| 延津县| 墨竹工卡县| 彭水| 怀来县| 东阳市| 根河市| 婺源县| 偃师市| 华蓥市| 鄄城县| 天峨县| 资溪县| 诸暨市| 江永县|