From c1366eb282b62b0fb14421f5c3884d087ca7ff7c Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 29 Dec 2017 14:01:46 +0800 Subject: [PATCH] update code style --- src/layouts/BasicLayout.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/layouts/BasicLayout.js b/src/layouts/BasicLayout.js index fb0a83f4..959225a2 100644 --- a/src/layouts/BasicLayout.js +++ b/src/layouts/BasicLayout.js @@ -66,7 +66,6 @@ class BasicLayout extends React.PureComponent { location: PropTypes.object, breadcrumbNameMap: PropTypes.object, } - state = { isMobile, }; @@ -78,9 +77,9 @@ class BasicLayout extends React.PureComponent { }; } componentDidMount() { - enquireScreen((b) => { + enquireScreen((mobile) => { this.setState({ - isMobile: !!b, + isMobile: mobile, }); }); } -- GitLab