Skip to content

Commit

Permalink
update MediaSource.buffer example once again
Browse files Browse the repository at this point in the history
  • Loading branch information
nitreojs committed Jun 10, 2022
1 parent b619362 commit 62887ed
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions packages/puregram/src/common/media-source/media-source.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,16 @@ export class MediaSource {
*
* @example
* ```js
* // imagine we have some variable like this
* // imagine we have some variable like this holding images
* const group: Buffer[] = [ ... ]
*
* context.sendMediaGroup(
* group.map(element => MediaSource.buffer(element))
* group.map(
* element => ({
* type: 'photo',
* media: MediaSource.buffer(element)
* })
* )
* )
* ```
*/
Expand Down

0 comments on commit 62887ed

Please sign in to comment.