Skip to content

Commit

Permalink
Add comment to useEffect explaining its usage
Browse files Browse the repository at this point in the history
  • Loading branch information
ST-KO committed Oct 22, 2024
1 parent 61bc217 commit ddf1de9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/CompareResults/ResultsTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@ export default function ResultsTable() {
new Map() as Map<string, Set<string>>, // ColumnID -> Set<Values to remove>
);

// This useEffect is to extract filter params from the URL (via rawSearchParams)
// and updates the tableFilters state.
useEffect(() => {
const filters = Array.from(rawSearchParams.entries())
.filter(([key]) => key.startsWith('filter'))
Expand Down

0 comments on commit ddf1de9

Please sign in to comment.