Add a method to set the skin (#787)

Fixes #733
This commit is contained in:
Jordan Eldredge 2019-05-21 07:58:18 -07:00 committed by GitHub
parent b4a88d2cc4
commit 29b4e0db71
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 16 additions and 0 deletions

View file

@ -375,6 +375,10 @@ const unsubscribe = webamp.onMinimize(() => {
unsubscribe();
```
### `setSkinFromUrl(url: string): void`
Updates the skin used by the webamp instance. Note that this does not happen immediately. If you want to be notified when the skin load is complete, use `.skinIsLoaded()`, which returns a promise which you can await.
### `skinIsLoaded(): Promise<void>`
Returns a promise that resolves when the skin is done loading.