mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-10-18 19:30:27 +08:00
Fix HomeSidebar repositories navigation
TIL that svelte5 reactivity doesn't apply to destructured renamed variables. By renaming `repos: initialRepos` and then using `initialRepos` in a `$state` rune, changes to the `repos` prop will not be taken into account.
This commit is contained in:
@@ -27,17 +27,10 @@
|
||||
}
|
||||
|
||||
/* eslint-disable prefer-const */
|
||||
let {
|
||||
config,
|
||||
repos: initialRepos,
|
||||
notificationCount,
|
||||
repoCount,
|
||||
activeTab,
|
||||
}: Props =
|
||||
let { config, repos, notificationCount, repoCount, activeTab }: Props =
|
||||
/* eslint-enable prefer-const */
|
||||
$props();
|
||||
|
||||
let repos = $state(initialRepos);
|
||||
let lock = false;
|
||||
const startup = $state<{ error?: ErrorWrapper }>({ error: undefined });
|
||||
|
||||
|
||||
Reference in New Issue
Block a user