Thank you for reading the article. Skeleton loading needs to be displayed until dynamic data is loaded.
Basically, if you have an isLoading prop on your component. While isLoading is true, component needs to display the skeleton. When data has finished loading and is ready to be displayed, isLoading is set to false and then you display the "real" component with data.
Mind elaborating on "#3 Conditionally load the skeleton in the main component" by posting the main component code?
TIA
Thank you for reading the article. Skeleton loading needs to be displayed until dynamic data is loaded.
Basically, if you have an
isLoadingprop on your component. WhileisLoadingistrue, component needs to display the skeleton. When data has finished loading and is ready to be displayed,isLoadingis set tofalseand then you display the "real" component with data.This is how it looks for my use-case.
Gotcha.. Thanks much!