File tree Expand file tree Collapse file tree 2 files changed +6
-7
lines changed
front/src/hoc/withSuspense Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Original file line number Diff line number Diff line change 1- // @flow
2-
31import withSuspense from './withSuspense' ;
42
53export default withSuspense ;
Original file line number Diff line number Diff line change 1- // @flow
2-
3- // #region imports
41import React , { Component , Suspense } from 'react' ;
2+ // @ts -ignore
53import wrapDisplayName from 'recompose/wrapDisplayName' ;
64import LoadingContent from '../../components/loadingContent' ;
7- // #endregion
85
96// #region flow types
107type Props = any ;
@@ -27,9 +24,13 @@ function withSuspense() {
2724 }
2825
2926 /* eslint-disable no-process-env */
27+ // @ts -ignore
3028 if ( process . env . NODE_ENV !== 'production' ) {
3129 // HOC would obfuscate component name, this trick is helpful for dev (we don't care in production)
32- WithSuspense . displayName = wrapDisplayName ( BaseComponent , 'withSuspense' ) ;
30+ ( WithSuspense as any ) . displayName = wrapDisplayName (
31+ BaseComponent ,
32+ 'withSuspense' ,
33+ ) ;
3334 }
3435 /* eslint-enable no-process-env */
3536
You can’t perform that action at this time.
0 commit comments