Skip to content

Commit 1eaede7

Browse files
authored
Startup perf improvements (keybase#20147)
1 parent d3db7f2 commit 1eaede7

100 files changed

Lines changed: 936 additions & 109 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎shared/__mocks__/react-list.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as React from 'react'
2-
import {clamp} from 'lodash-es'
2+
import clamp from 'lodash/clamp'
33

44
if (!__STORYBOOK__) {
55
throw new Error('Invalid load of mock')

‎shared/actions/settings.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ import * as RouteTreeGen from './route-tree-gen'
1010
import * as RPCTypes from '../constants/types/rpc-gen'
1111
import * as SettingsGen from './settings-gen'
1212
import * as WaitingGen from './waiting-gen'
13-
import {mapValues, trim} from 'lodash-es'
13+
import mapValues from 'lodash/mapValues'
14+
import trim from 'lodash/trim'
1415
import {delay} from 'redux-saga'
1516
import {isAndroidNewerThanN, isTestDevice, pprofDir, version} from '../constants/platform'
1617
import {writeLogLinesToFile} from '../util/forward-logs'

‎shared/chat/avatars.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import * as React from 'react'
22
import * as Kb from '../common-adapters'
33
import * as Styles from '../styles'
44
import shallowEqual from 'shallowequal'
5-
import {memoize} from 'lodash-es'
5+
import memoize from 'lodash/memoize'
66

77
// All this complexity isn't great but the current implementation of avatar forces us to juggle all these colors and
88
// forces us to explicitly choose undefined/the background/ etc. This can be cleaned up when avatar is simplified

‎shared/chat/conversation/info-panel/attachments.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import * as Styles from '../../../styles'
77
import {imgMaxWidthRaw} from '../messages/attachment/image/image-render'
88
import {formatTimeForMessages} from '../../../util/timestamp'
99
import MessagePopup from '../messages/message-popup'
10-
import {chunk} from 'lodash-es'
10+
import chunk from 'lodash/chunk'
1111
import {OverlayParentProps} from '../../../common-adapters/overlay/parent-hoc'
1212
import {Section} from '.'
1313

‎shared/chat/conversation/info-panel/min-writer-role/index.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import * as Kb from '../../../../common-adapters'
33
import * as TeamTypes from '../../../../constants/types/teams'
44
import * as TeamConstants from '../../../../constants/teams'
55
import * as Style from '../../../../styles'
6-
import {upperFirst} from 'lodash-es'
6+
import upperFirst from 'lodash/upperFirst'
77

88
type Props = {
99
canSetMinWriterRole: boolean

‎shared/chat/conversation/input-area/normal/index.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ import {emojiIndex} from 'emoji-mart'
77
import PlatformInput from './platform-input'
88
import {standardTransformer} from '../suggestors'
99
import {InputProps} from './types'
10-
import {debounce, throttle} from 'lodash-es'
10+
import debounce from 'lodash/debounce'
11+
import throttle from 'lodash/throttle'
1112
import {memoize} from '../../../../util/memoize'
1213
import CommandMarkdown from '../../command-markdown/container'
1314
import CommandStatus from '../../command-status/container'

‎shared/chat/conversation/input-area/suggestors/index.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import * as React from 'react'
22
import * as Kb from '../../../../common-adapters'
33
import * as Styles from '../../../../styles'
4-
import {invert} from 'lodash-es'
4+
import invert from 'lodash/invert'
55
import SuggestionList from './suggestion-list'
66

77
type TransformerData = {

‎shared/chat/conversation/list-area/normal/index.desktop.tsx‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ import shallowEqual from 'shallowequal'
1717
import {ErrorBoundary} from '../../../../common-adapters'
1818
import {Props} from '.'
1919
import {Waypoint} from 'react-waypoint'
20-
import {debounce, throttle, chunk} from 'lodash-es'
20+
import debounce from 'lodash/debounce'
21+
import throttle from 'lodash/throttle'
22+
import chunk from 'lodash/chunk'
2123
import {globalMargins} from '../../../../styles/shared'
2224
import {memoize} from '../../../../util/memoize'
2325

‎shared/chat/conversation/messages/coinflip/results.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as React from 'react'
2-
import {partition} from 'lodash-es'
2+
import partition from 'lodash/partition'
33
import * as Kb from '../../../../common-adapters'
44
import * as Styles from '../../../../styles'
55
import * as RPCChatTypes from '../../../../constants/types/rpc-chat-gen'

‎shared/chat/conversation/messages/message-popup/payment/index.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as React from 'react'
2-
import {toUpper, upperFirst} from 'lodash-es'
2+
import toUpper from 'lodash/toUpper'
3+
import upperFirst from 'lodash/upperFirst'
34
import * as Styles from '../../../../../styles'
45

56
import {Position} from '../../../../../common-adapters/relative-popup-hoc.types'

0 commit comments

Comments
 (0)