Skip to content

Commit

Permalink
fix(website): copy array of projects before sorting
Browse files Browse the repository at this point in the history
  • Loading branch information
cedoor committed Jan 10, 2024
1 parent 767df87 commit 3fbf442
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/website/src/components/ProjectsList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import IconPSE from "../icons/IconPSE"
import { chunkArray } from "../utils/chunkArray"
import { getProjectCategories } from "../utils/getProjectCategories"

const sortedProjects = allProjects.sort((a, b) => a.name.localeCompare(b.name))
const sortedProjects = allProjects.slice().sort((a, b) => a.name.localeCompare(b.name))

export default function ProjectsList(props: any) {
const [projects, setProjects] = useState<(typeof allProjects)[]>(chunkArray(sortedProjects))
Expand Down

0 comments on commit 3fbf442

Please sign in to comment.