From c3294dfc648e5093cdfd8f87aad2ba143a37240f Mon Sep 17 00:00:00 2001 From: afc163 Date: Tue, 18 Aug 2015 20:27:40 +0800 Subject: [PATCH] use arrow function --- components/modal/index.jsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/components/modal/index.jsx b/components/modal/index.jsx index 8f2a294f6..e61711586 100644 --- a/components/modal/index.jsx +++ b/components/modal/index.jsx @@ -63,9 +63,7 @@ export default React.createClass({ // 100ms 内发生过点击事件,则从点击位置动画展示 // 否则直接 zoom 展示 // 这样可以兼容非点击方式展开 - setTimeout(function() { - mousePosition = null; - }, 100); + setTimeout(() => mousePosition = null, 100); }); mousePositionEventBinded = true; },