use-sound

A React Hook for playing sound effects (by joshwcomeau)

Use-sound Alternatives

Similar projects and alternatives to use-sound

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a better use-sound alternative or higher similarity.

use-sound reviews and mentions

Posts with mentions or reviews of use-sound. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-02-22.
  • [Question]: Play sounds inside useEffect in a multiplayer online game
    2 projects | /r/reactjs | 22 Feb 2023
    As some of you may know, sounds can only be played back after the user has interacted with the document. And this seems to be exactly where it is becoming tricky. I tried a very promising library called use-sound. However as it turns out it is currently impossible to trigger a sound effect on useEffect with this, as tracked in this issue: https://github.com/joshwcomeau/use-sound/issues/100. Somehow it works whenever the dev server hot reloads - and then it is really snappy, but I can't make it work on initial page load.
  • Building a Music Player in React
    4 projects | dev.to | 16 Dec 2022
    use-sound: This will handle the audio file. It will load, play, and pause the audio along with other features.
  • Chrome does not allow meadi autoplay since 2018 - but some websites are still able to do it. How?
    1 project | /r/webdev | 8 Nov 2022
    However, after a lot of experimenting, I was able to play a sound in chrome when I explicitly enabled sound for our url in the chrome site settings, but only as long as the tab was in focus it would play. I was using this react library to do so: https://www.npmjs.com/package/use-sound you can find a proof of concept on the developers website: https://www.joshwcomeau.com/react/announcing-use-sound-react-hook/ if you scroll a bit down there will be a few things you can click that will trigger a sound - but all of them requires a browser event!
  • Best audio handling library for React in 2022?
    4 projects | /r/reactjs | 30 Oct 2022
    use-sound
  • How to play sound on button click in Next.js app?
    1 project | /r/nextjs | 15 Sep 2022
    I found this use-sound package for react when I'm trying to import audio file I'm getting this error. Cannot find the .mp3 file.
  • How to reproduce Death Stranding UI with react and react-three-fiber
    12 projects | dev.to | 15 Apr 2021
    For the sounds part we’re going to create a sound manager component using useSound hook from Joshua Comeau. After that, we’re going to put our sound functions newly-created into our state so that we can everywhere in the app.
  • The Only React Hook for Sound Effects You Will Ever Need
    2 projects | dev.to | 24 Feb 2021
    sprite allows you to use a single useSound hook for multiple sound effects. See “Sprites” below.
  • A note from our sponsor - SurveyJS
    surveyjs.io | 27 Apr 2024
    With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js. Learn more →

Stats

Basic use-sound repo stats
7
2,509
0.0
22 days ago

Sponsored
Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com