webplayer

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 16, 2026 License: GPL-3.0 Imports: 8 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Rendered for js/wasm

Overview

Package webplayer bridges Spotify's documented Web Playback SDK to Go.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Player

type Player struct {
	// contains filtered or unexported fields
}

Player owns the SDK object and its JS callbacks.

func New

func New(name string, getToken func(context.Context) (string, error)) *Player

func (*Player) ActivateElement

func (p *Player) ActivateElement() error

func (*Player) Connect

func (p *Player) Connect(ctx context.Context) error

func (*Player) Disconnect

func (p *Player) Disconnect() error

func (*Player) Events

func (p *Player) Events() <-chan webspotify.SDKEvent

func (*Player) SetName

func (p *Player) SetName(ctx context.Context, name string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL