feat: can handle bigint data#186
Merged
AlemTuzlak merged 3 commits intocode-forge-io:mainfrom Feb 18, 2025
Merged
Conversation
commit: |
AlemTuzlak
reviewed
Feb 3, 2025
| @@ -0,0 +1,17 @@ | |||
| export const bigIntReplacer = (key: any, value: any) => (typeof value === "bigint" ? value.toString() : value) | |||
|
|
|||
| export const convertBigIntToString = (data: any): any => { | |||
Contributor
There was a problem hiding this comment.
I'm pretty sure this util wouldn't work if the bigInt is nested?
Contributor
Author
There was a problem hiding this comment.
@AlemTuzlak thanks for commenting. I wrote test about it. I think nested object can be converted.
https://github.com/forge-42/react-router-devtools/pull/186/files#diff-cbeddc41b1f357bd9fa39701fe1fdf8a19fff65302ad77bc23252a6ac3b00d90
AlemTuzlak
approved these changes
Feb 18, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes #185
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
I added returning bigint code in test-apps and check loader and action can handle bigint.
I want to add unit tests but can't figure out appropriate position to place tests.
Checklist: