disable twitter-handler
This commit is contained in:
@ -33,7 +33,6 @@ import { PipedVideoHandler } from './websites/piped-video-handler'
|
||||
import { ScrapingBeeHandler } from './websites/scrapingBee-handler'
|
||||
import { StackOverflowHandler } from './websites/stack-overflow-handler'
|
||||
import { TDotCoHandler } from './websites/t-dot-co-handler'
|
||||
import { TwitterHandler } from './websites/twitter-handler'
|
||||
import { WeixinQqHandler } from './websites/weixin-qq-handler'
|
||||
import { WikipediaHandler } from './websites/wikipedia-handler'
|
||||
import { YoutubeHandler } from './websites/youtube-handler'
|
||||
@ -65,7 +64,6 @@ const contentHandlers: ContentHandler[] = [
|
||||
new PdfHandler(),
|
||||
new ScrapingBeeHandler(),
|
||||
new TDotCoHandler(),
|
||||
new TwitterHandler(),
|
||||
new YoutubeHandler(),
|
||||
new WikipediaHandler(),
|
||||
new GitHubHandler(),
|
||||
|
||||
@ -46,11 +46,11 @@ export class NitterHandler extends ContentHandler {
|
||||
context = await browser.createIncognitoBrowserContext()
|
||||
const page = await context.newPage()
|
||||
|
||||
// // Modify this variable to control the size of viewport
|
||||
// const deviceScaleFactor = 0.2
|
||||
// const height = Math.floor(2000 / deviceScaleFactor)
|
||||
// const width = Math.floor(1700 / deviceScaleFactor)
|
||||
// await page.setViewport({ width, height, deviceScaleFactor })
|
||||
// Modify this variable to control the size of viewport
|
||||
const deviceScaleFactor = 0.2
|
||||
const height = Math.floor(2000 / deviceScaleFactor)
|
||||
const width = Math.floor(1700 / deviceScaleFactor)
|
||||
await page.setViewport({ width, height, deviceScaleFactor })
|
||||
|
||||
await page.goto(url, {
|
||||
waitUntil: 'networkidle2',
|
||||
|
||||
Reference in New Issue
Block a user