This repository was archived by the owner on Jan 29, 2026. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed
packages/tds-widget/src/review/components/shorten-list Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -42,8 +42,12 @@ export function ReviewsList({
4242 const [ selectedReviewId , setSelectedReviewId ] = useState < string | undefined > (
4343 undefined ,
4444 )
45- const { subscribeLikedChangeEvent, unsubscribeLikedChangeEvent } =
46- useClientAppActions ( )
45+ const {
46+ subscribeLikedChangeEvent,
47+ unsubscribeLikedChangeEvent,
48+ subscribeReviewUpdateEvent,
49+ unsubscribeReviewUpdateEvent,
50+ } = useClientAppActions ( )
4751
4852 const { data : myReviewData } = useMyReview ( {
4953 resourceId,
@@ -80,6 +84,12 @@ export function ReviewsList({
8084 return ( ) => unsubscribeLikedChangeEvent ?.( refetch )
8185 } , [ refetch , subscribeLikedChangeEvent , unsubscribeLikedChangeEvent ] )
8286
87+ useEffect ( ( ) => {
88+ subscribeReviewUpdateEvent ?.( refetch )
89+
90+ return ( ) => unsubscribeReviewUpdateEvent ?.( refetch )
91+ } , [ refetch , subscribeReviewUpdateEvent , unsubscribeReviewUpdateEvent ] )
92+
8393 if ( ! myReviewData || ! descriptionsData || ! sortedReviews ) {
8494 return < Spinner />
8595 }
You can’t perform that action at this time.
0 commit comments