Skip to content

Method to set source #151

@rtritto

Description

@rtritto

If the feature request is for a plugin or provider, specify it here.

No response

If the feature solves a problem you have, specify it here.

After the player loads a source, it can't be updated with a new one.

Describe the proposed feature.

Add a method to update the source of the player:

player.setSource(new_source)  // OR player.setSrc(new_source) OR player.src(new_source)

Describe alternatives you've considered

I tried to update the value of src attribute, but the player doesn't load the new source.

  • Code of the first try:

    <video id="player" class="vlite-js">
      <source src={source_variable} />
    </video>
  • Code of the second try:

    <video id="player" class="vlite-js" src={source_variable} />

Additional context

No response

Related issues

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions