fix: list should have unique "key" in web application page#5502
fix: list should have unique "key" in web application page#5502khanhtc1202 merged 1 commit intomasterfrom
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #5502 +/- ##
=======================================
Coverage 26.28% 26.29%
=======================================
Files 464 464
Lines 49624 49626 +2
=======================================
+ Hits 13043 13047 +4
+ Misses 35547 35546 -1
+ Partials 1034 1033 -1 ☔ View full report in Codecov by Sentry. |
72c046a to
77a2f53
Compare
| </Fragment> | ||
| ) : ( | ||
| <> | ||
| <Fragment key={v.version}> |
There was a problem hiding this comment.
[ASK]
v.version is already used in L178. Is that OK?
(I'm sorry, but I'm not familiar with React)
There was a problem hiding this comment.
Thanks for asking,
Yes, @t-kikuc it is the same key for 1 record when map from recentlyDeployment.versionsList.
The error show that we need uniq key for each child when map from recentlyDeployment.versionsList so I use v.version as uniq key.
There was a problem hiding this comment.
Thank @Warashi !
I update the pull with key ${v.name}:${v.version}
The key is just needs to be unique in a single cell, so the name and version of artifacts in a single row must be different, right?
There was a problem hiding this comment.
Thanks @hongky-1994 !
the name and version of artifacts in a single row must be different, right?
Yes, I think so. The combination of name and version is safe as a unique key in a single row.
Signed-off-by: kypham <hongkyhvnh@gmail.com>
77a2f53 to
b1c1d1c
Compare


What this PR does:
Fix error log in console web
Why we need it:
Which issue(s) this PR fixes:
Does this PR introduce a user-facing change?:
No