mirror of
https://github.com/LuanRT/YouTube.js.git
synced 2026-07-02 13:07:28 +00:00
refactor: migrate parsers to TS (#133)
* dev: finish top-level parsers TS migration
* dev: migrate menu renderers to TS
* chore: fix ts errors
* dev: finish ts migration 🎉
This commit is contained in:
19
src/parser/classes/TwoColumnWatchNextResults.ts
Normal file
19
src/parser/classes/TwoColumnWatchNextResults.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import Parser from '../index';
|
||||
import { YTNode } from '../helpers';
|
||||
|
||||
class TwoColumnWatchNextResults extends YTNode {
|
||||
static type = 'TwoColumnWatchNextResults';
|
||||
|
||||
results;
|
||||
secondary_results;
|
||||
conversation_bar;
|
||||
|
||||
constructor(data: any) {
|
||||
super();
|
||||
this.results = Parser.parse(data.results?.results.contents, true);
|
||||
this.secondary_results = Parser.parse(data.secondaryResults?.secondaryResults.results, true);
|
||||
this.conversation_bar = Parser.parse(data?.conversationBar);
|
||||
}
|
||||
}
|
||||
|
||||
export default TwoColumnWatchNextResults;
|
||||
Reference in New Issue
Block a user