Speed up image rotation
This commit is contained in:
parent
198cf4b3b9
commit
b1d1a523ee
1 changed files with 1 additions and 1 deletions
|
|
@ -9,7 +9,7 @@ const ImageCarousel: React.FC = () => {
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const timer = setInterval(() => {
|
const timer = setInterval(() => {
|
||||||
setCurrentIndex((prevIndex) => (prevIndex + 1) % images.length);
|
setCurrentIndex((prevIndex) => (prevIndex + 1) % images.length);
|
||||||
}, 10000);
|
}, 5000);
|
||||||
|
|
||||||
return () => clearInterval(timer);
|
return () => clearInterval(timer);
|
||||||
}, []);
|
}, []);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue