Skip to content

Commit

Permalink
added audio loop
Browse files Browse the repository at this point in the history
  • Loading branch information
gpillon committed Feb 24, 2024
1 parent 0f9dde1 commit f4eecde
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/contexts/AudioContext.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export const AudioProvider: FunctionComponent<AudioProviderProps> = ({ children
const [isPlaying, setIsPlaying] = useState(false);
const [hasBeenInitiated, setHasBeenInitiated] = useState(false);

audio.loop = true;
const autoPlay = () => {
if (!hasBeenInitiated) {
setHasBeenInitiated(true);
Expand Down

0 comments on commit f4eecde

Please sign in to comment.