2019-10-19
Ajax spinner animation
Sometimes an ajax spinner is need, to indicate that the user need to wait.
The code below will make the .spinner
to spin as soon as the page has been loaded.
.spinner {
animation: spin 2s linear infinite;
}
@keyframes spin {
100% {
transform:rotate(360deg);
}
}
For the spinner to do what it is supposed to do, you should probably hide and show this element depending on if an element loads or not.
Comments