Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

Decouple AudioController from audio in favour of headless Audio #460

Closed
1 task
dhruvkb opened this issue Nov 30, 2021 · 0 comments
Closed
1 task

Decouple AudioController from audio in favour of headless Audio #460

dhruvkb opened this issue Nov 30, 2021 · 0 comments
Assignees
Labels
💻 aspect: code Concerns the software code in the repository ✨ goal: improvement Improvement to an existing user-facing feature 🟧 priority: high Stalls work on the project or its dependents

Comments

@dhruvkb
Copy link
Member

dhruvkb commented Nov 30, 2021

Problem

New features in audio would require the AudioTrack component to be rendered and unrendered as per the circumstances. Also for a responsive experience, the player would need to switch between several different layouts, which can cause a re-render. With the current setup where the <audio> element is a part of the component, the playback would be interrupted when the component is re-rendered.

Description

Decoupling <audio> from the AudioController would allow the playback to continue uninterrupted in the background while the view in the foreground goes through its lifecycle events. Replacing each individual audio player element with a unified Audio object in the store would be helpful for uninterrupted playback.

Alternatives

I can't think of any alternatives.

Additional context

Using a common object would cause issues as information that was previously held in the <audio> element such as duration and current time would need to be stored separately.

Implementation

  • 🙋 I would be interested in implementing this feature.
@dhruvkb dhruvkb added 🟧 priority: high Stalls work on the project or its dependents ✨ goal: improvement Improvement to an existing user-facing feature 💻 aspect: code Concerns the software code in the repository labels Nov 30, 2021
@dhruvkb dhruvkb self-assigned this Dec 3, 2021
@dhruvkb dhruvkb closed this as completed Feb 17, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
💻 aspect: code Concerns the software code in the repository ✨ goal: improvement Improvement to an existing user-facing feature 🟧 priority: high Stalls work on the project or its dependents
Projects
None yet
Development

No branches or pull requests

1 participant