mirror of
https://github.com/LuanRT/YouTube.js.git
synced 2026-06-13 09:32:12 +00:00
chore(Comments): reword a few things in the docs
This commit is contained in:
@@ -25,11 +25,11 @@ A list of comment threads. **Note:** More about comment threads [**here**](./Com
|
||||
|
||||
<a name="applysort"></a>
|
||||
### applySort(sort)
|
||||
Sorts the comments with the given sort type.
|
||||
Applies given sort option to the comments.
|
||||
|
||||
| Param | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| sort | `string` | Sort type. Can be `TOP_COMMENTS`, `NEWEST_FIRST` |
|
||||
| sort | `string` | Sort option. Can be `TOP_COMMENTS`, `NEWEST_FIRST` |
|
||||
|
||||
**Returns:** [`Promise.<Comments>`](../../src/parser/youtube/Comments.ts)
|
||||
|
||||
|
||||
@@ -43,12 +43,12 @@ class Comments {
|
||||
}
|
||||
|
||||
/**
|
||||
* Sorts the comments with the given sort type.
|
||||
* Applies given sort option to the comments.
|
||||
* @param sort - Sort type.
|
||||
*/
|
||||
async applySort(sort: 'TOP_COMMENTS' | 'NEWEST_FIRST'): Promise<Comments> {
|
||||
if (!this.header)
|
||||
throw new InnertubeError('Page header is missing. Cannot apply sort filter.');
|
||||
throw new InnertubeError('Page header is missing. Cannot apply sort option.');
|
||||
|
||||
let button;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user