Page MenuHomePhabricator

[native] [reactor] [ENG-530] fix hot reload export issue in chat message
ClosedPublic

Authored by benschac on May 9 2022, 12:32 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Apr 2, 4:11 AM
Unknown Object (File)
Mon, Mar 31, 11:05 PM
Unknown Object (File)
Mon, Mar 31, 4:55 PM
Unknown Object (File)
Mon, Mar 31, 6:57 AM
Unknown Object (File)
Mon, Mar 31, 12:05 AM
Unknown Object (File)
Sat, Mar 29, 2:32 AM
Unknown Object (File)
Tue, Mar 25, 6:57 PM
Unknown Object (File)
Wed, Mar 19, 8:45 PM

Details

Summary

Fix hot reload issues coming from react components exported with additional variables https://twitter.com/benschac/status/1521867664267821063?s=20&t=hKhwNWhJqqDsPU5nB2Qexw

Test Plan

no functional change. when editing chat-list.react.js hot-reload will not push the engineer back to the inbox.

Diff Detail

Repository
rCOMM Comm
Branch
inline-sidebar-web-and-native-ENG-530
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

Makes sense to pull out the helper function.

Is there a reason we call this file chat-message-constants? I might be missing something but it doesn't look like we're keeping constant values in it?

Maybe something like chat-message-utils?

This revision is now accepted and ready to land.May 10 2022, 6:52 AM
In D3972#111889, @atul wrote:

Makes sense to pull out the helper function.

Is there a reason we call this file chat-message-constants? I might be missing something but it doesn't look like we're keeping constant values in it?

Maybe something like chat-message-utils?

I just named it that because that's what I named the other files that had removed additional exports from (that broke hot reload). I was thinking of just moving all of the constants into one utils file now that there are a couple of different constants files.

Addressed @atul's comment here: https://phabricator.ashoat.com/D3996 moved chatMessageItemKey into the util chat/util file.