Skip to content

Conversation

@ulrikandersen
Copy link
Contributor

@ulrikandersen ulrikandersen commented Sep 29, 2025

Uses "refreshing" state to show loading indicator while project cache is being refreshed. This is especially useful when the user is requesting a project, branch og spec that is not in the cache.

The PR removes the SecondaryHeaderPlaceholder and just shows the main loading indicator.

Demo:

Skaermoptagelse.2025-09-29.kl.20.57.12.mov

while project cache is refreshed
const [refreshed, setRefreshed] = useState<boolean>(true);
const [projects, setProjects] = useState<Project[]>(initialProjects || []);
const isLoadingRef = useRef(false);
const [refreshing, setRefreshing] = useState(false);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps we do not need const isLoadingRef = useRef(false)?

@oscarlund121 oscarlund121 merged commit 315a43e into optimize-project-doc-loadtime Sep 30, 2025
3 of 5 checks passed
@oscarlund121 oscarlund121 deleted the show-loading-while-refreshing branch September 30, 2025 08:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants