Skip to content

Commit

Permalink
Updated ReadMe
Browse files Browse the repository at this point in the history
  • Loading branch information
SvenTiigi committed Sep 28, 2021
1 parent 13da33a commit f4dc06b
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ To integrate using Apple's [Swift Package Manager](https://swift.org/package-man

```swift
dependencies: [
.package(url: "https://github.com/SvenTiigi/YouTubePlayerKit.git", from: "1.0.0")
.package(url: "https://github.com/SvenTiigi/YouTubePlayerKit.git", from: "1.1.0")
]
```

Expand Down Expand Up @@ -263,14 +263,23 @@ youTubePlayer.playbackRatePublisher
// Retrieve a number between 0 and 1 that specifies the percentage of the video that the player shows as buffered
youTubePlayer.getVideoLoadedFraction { _ in }

// A Publisher that emits a number between 0 and 1 that specifies the percentage of the video that the player shows as buffered
youTubePlayer.videoLoadedFractionPublisher()

// Retrieve the PlaybackState of the player video
youTubePlayer.getPlaybackState { _ in }

// Retrieve the elapsed time in seconds since the video started playing
youTubePlayer.getCurrentTime { _ in }

/// A Publisher that emits the current elapsed time in seconds since the video started playing
youTubePlayer.currentTimePublisher()

// Retrieve the current PlaybackMetadata
youTubePlayer.getPlaybackMetadata { _ in }

// A Publisher that emits the current PlaybackMetadata
youTubePlayer.playbackMetadataPublisher
```

#### Load/Cue video
Expand Down Expand Up @@ -320,6 +329,9 @@ youTubePlayer.set(volume: 50)
// Retrieve the duration in seconds of the currently playing video
youTubePlayer.getDuration { _ in }

// A Publisher that emits the duration in seconds of the currently playing video
youTubePlayer.durationPublisher

// Retrieve the YouTube.com URL for the currently loaded/playing video
youTubePlayer.getVideoURL { _ in }

Expand Down

0 comments on commit f4dc06b

Please sign in to comment.