arwes / arwes

Futuristic Sci-Fi UI Web Framework.

Home Page:https://arwes.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Remove Howler.js depencency from bleeps package

romelperez opened this issue · comments

The package @arwes/sounds was renamed to @arwes/bleeps for v1.0.0-alpha.20. You can see the latest changes in the next branch.


The package @arwes/bleeps uses the dependency package howler to manipulate the browser sound API internally. Howler simplifies the manipulation but Arwes needs only a few APIs, not everything that comes with Howler. For example, it is a lot of file size added for what it is needed for.

  • Remove howler package dependency from @arwes/bleeps.

Notes:

  • Only latest version of Chrome, Firefox, and Safari browsers, for Android, iOS and desktop are supported.
  • The API to support multiple audio files should still be supported. This will involve to review how to implement in a simple manner the audio file support detection and audio file preloading.
  • Audio files should be preloaded on definition time, not on playback time, as Howler does it.
  • The related sandboxes used in the playground application should be used to test the functionalities.
  • There are some edge-cases which should be test:
    • No sounds should be played when the browser has locked audio playback. And no errors should be shown.
    • Sounds should only be played when applicable when browser audio playback is unlocked.
  • No other dependencies should be added. The Web Audio API should be used.

The bleeps API now works directly with the Web Audio API instead of Howler.js.