Default allocator options are used on rendered scraping. It can be changed using custom Client or changing client options after scraper creation.

This commit is contained in:
Musab Gültekin 2021-05-23 23:48:55 +03:00
parent 5aa2c2540e
commit a2a91b7b2e

View File

@ -1,6 +1,7 @@
package geziyor
import (
"github.com/chromedp/chromedp"
"github.com/geziyor/geziyor/cache"
"github.com/geziyor/geziyor/client"
"github.com/geziyor/geziyor/export"
@ -77,6 +78,7 @@ func NewGeziyor(opt *Options) *Geziyor {
RetryTimes: opt.RetryTimes,
RetryHTTPCodes: opt.RetryHTTPCodes,
RemoteAllocatorURL: opt.BrowserEndpoint,
AllocatorOptions: chromedp.DefaultExecAllocatorOptions[:],
})
if opt.Cache != nil {
geziyor.Client.Transport = &cache.Transport{