Repository navigation
Localize memoize - #50698
Localize memoize#50698
Conversation
|
|
||
| /** | ||
| * Checks if the cache should be skipped for the given arguments. | ||
| * @param args Tuple of arguments passed to the memoized function. Does not work with constructable (see description). |
There was a problem hiding this comment.
@kacper-mikolajczak Can you tell me reason for this? I just copied this from transformKey description.
There was a problem hiding this comment.
@shubham1206agra IIRC the transformKey did not work for constructables but it was fixed.
One of the exceptions is Intl.NumberFormat from NumberFormatUtils module.
However, for other constructables and it works:
- custom classes
- other constructables APIs (e.g.
ResizeObserver,URL)
In this case I think we can remove the warning or change it to be more descriptive 👍
There was a problem hiding this comment.
Update!
After testing it more carefully, it looks like it has an issue with resolving arguments for other APIs as well. For example FormData arguments are merged into union as it happens for NumberFormat.
What they have in common is that all the arguments are optional - it may be a good starting point for investigations
There was a problem hiding this comment.
What they have in common is that all the arguments are optional - it may be a good starting point for investigations
@kacper-mikolajczak I assume we will investigate this point in another issue, won't we?
There was a problem hiding this comment.
Definitely, let's make it separate issue!
|
@hoangzinh Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
|
@hoangzinh Waiting for your review here |
|
@shubham1206agra oh yes, planned to review today |
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2024-10-23.at.23.30.09.android.movAndroid: mWeb ChromeScreen.Recording.2024-10-23.at.23.32.54.android.chrome.moviOS: NativeScreen.Recording.2024-10-23.at.23.33.53.ios.moviOS: mWeb SafariScreen.Recording.2024-10-23.at.23.36.31.ios.safari.movMacOS: Chrome / SafariScreen.Recording.2024-10-23.at.23.22.55.web.movMacOS: DesktopScreen.Recording.2024-10-23.at.23.28.22.desktop.mov |
|
Hi @shubham1206agra we're missing recording for Android platform, can you add it? |
|
@hoangzinh Done |
|
cc @kacper-mikolajczak @mountiny for 2nd review round |
kacper-mikolajczak
left a comment
There was a problem hiding this comment.
Just a tiny nitpick and LGTM <3
Let's be mindful and observe whether users of memoize module are fine with current API - the skipCache is triggered before maxArgs and transformKey but it could also have different placement in a pipeline.
This can be emphasized in a JSDoc as well.
Co-authored-by: Kacper Mikołajczak <62747088+kacper-mikolajczak@users.noreply.github.com>
mountiny
left a comment
There was a problem hiding this comment.
Thank you, changes look good to me
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.0.56-0 🚀
|
|
🚀 Deployed to production by https://github.com/Julesssss in version: 9.0.56-9 🚀
|
Details
Fixed Issues
$ #50194
PROPOSAL: #50194 (comment)
Tests
Test the whole App and confirm that the translations are correct
Offline tests
Same as Tests
QA Steps
Same as Tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Screen.Recording.2024-10-24.at.3.22.06.PM.mov
Android: mWeb Chrome
Screen.Recording.2024-10-14.at.2.23.44.PM.mov
iOS: Native
Screen.Recording.2024-10-14.at.2.31.39.PM.mov
iOS: mWeb Safari
Screen.Recording.2024-10-14.at.2.20.00.PM.mov
MacOS: Chrome / Safari
Screen.Recording.2024-10-14.at.2.12.39.PM.mov
MacOS: Desktop
Screen.Recording.2024-10-14.at.2.27.05.PM.mov