Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/N0taN3rd/Squidwarc
/ functions
Functions
175 in github.com/N0taN3rd/Squidwarc
⨍
Functions
175
◇
Types & classes
38
↓ 18 callers
Method
cyan
* @desc Cyan colored console.log * @param args
lib/utils/colorPrinters.js:77
↓ 17 callers
Method
crawlerOpt
* @desc Display an crawler option ack * @param f * @param r
lib/utils/colorPrinters.js:113
↓ 14 callers
Method
bred
* @desc Bright red colored console.log * @param args
lib/utils/colorPrinters.js:61
↓ 12 callers
Method
error
* @desc Display an error message and pretty print the exception * @param {string} m - The message to display * @param {Error} error - The except
lib/utils/colorPrinters.js:94
↓ 11 callers
Method
addEventListener
* @desc Register an eventName, eventListener pairs on an EventEmitter * @param {!EventEmitter} emitter - The EventEmitter to register the eventName
lib/crawler/helper.js:40
↓ 10 callers
Method
blue
* @desc Blue colored console.log * @param args
lib/utils/colorPrinters.js:69
↓ 6 callers
Method
_emitEvent
* @desc Emit an event * @param {string} event - The event name to be emitted * @param [arg] - The value to be emitted for the event
lib/crawler/navigationMan.js:243
↓ 6 callers
Function
bingo
* @desc Tests (T|F) to see if the execPath is executable by this process * @param {string} execPath - The executable path to test * @returns {Promis
lib/launcher/chromeFinder.js:96
↓ 6 callers
Method
next
* @desc Get the next URL to crawl from the frontier, queue length - 1 * @return {?string}
lib/frontier/index.js:101
↓ 5 callers
Function
ensureOptions
* @param {ChromeOptions} options * @return {?ChromeOptions}
lib/launcher/chrome.js:32
↓ 5 callers
Function
exec
* @desc Executes the supplied command * @param {string} someCommand * @param {boolean} [rejectOnError = false] * @returns {Promise<string>}
lib/launcher/chromeFinder.js:36
↓ 5 callers
Method
exhausted
* @desc Is the frontier exhausted * @return {boolean}
lib/frontier/index.js:93
↓ 5 callers
Method
navigate
* @desc Navigate to a new Web Page * @param {string} url - The url to navigate the browser to
lib/crawler/chrome.js:188
↓ 5 callers
Method
size
* @desc Returns the number of URLs left in the queue * @return {number}
lib/frontier/index.js:85
↓ 4 callers
Method
crawlModeToSymbol
* @desc Retrieve the crawl-mode symbol from a configs string * @param {string} mode - The crawl mode * @returns {symbol} - The crawl modes inter
lib/frontier/helper.js:69
↓ 4 callers
Method
red
* @desc Red colored console.log * @param args
lib/utils/colorPrinters.js:53
↓ 4 callers
Method
seenURL
* @desc Have we seen the supplied URL * @param {string} url - The URL to check if we have seen it * @returns {boolean}
lib/frontier/seedTracker.js:81
↓ 4 callers
Method
shutdown
* @desc Disconnect from the Chrome instance currently attached to
lib/crawler/chrome.js:223
↓ 3 callers
Function
cleanup
()
lib/launcher/chrome.js:304
↓ 3 callers
Method
getWarcNamingFunction
* @desc Configures the function that produces the WARC(s) name * @param {CrawlConfig} options
lib/utils/warcNaming.js:77
↓ 3 callers
Method
init
* @desc Initialize the initial frontier * @param {Seed[] | Seed} starting
lib/frontier/index.js:51
↓ 2 callers
Method
_clearTimers
* @desc Clear all timers * @private
lib/crawler/netIdleWatcher.js:195
↓ 2 callers
Method
_clearTimers
* @desc Clear all timers * @private
lib/crawler/navigationMan.js:223
↓ 2 callers
Method
addToSeen
* @desc Adds a URL to the set of URLs seen and increments the seeds URL count * @param {string} url - The URL to mark as seen
lib/frontier/seedTracker.js:89
↓ 2 callers
Function
chromeArgs
* * @param {ChromeOptions} options * @param {string} userDataDir * @return {string[]}
lib/launcher/chrome.js:51
↓ 2 callers
Method
configError
* @desc Display message about how the crawl config is broke * @param m * @param config
lib/utils/colorPrinters.js:122
↓ 2 callers
Method
connect
* @desc Connect to an running instance of Chrome * @param {?ChromeOptions} [options] * @return {Promise<CRI>}
lib/launcher/chrome.js:233
↓ 2 callers
Method
done
* @desc Are there no more URLs to be crawled that are associated with this seed * @returns {boolean}
lib/frontier/seedTracker.js:65
↓ 2 callers
Method
extractLinks
()
lib/injectManager/pageInjects/collectLinks.js:73
↓ 2 callers
Method
findChrome
* @desc Finds an acceptable Chrome or Chromium executable. * If the env key 'CHROME_PATH' is defined that is returned by default * @returns {Pro
lib/launcher/chromeFinder.js:115
↓ 2 callers
Method
getCrawlInjects
* @desc JS injected into every frame of the page crawled that includes disabling things that can act as an crawler trap, JS that scrolls the page auto
lib/injectManager/index.js:126
↓ 2 callers
Method
green
* @desc Green colored console.log * @param args
lib/utils/colorPrinters.js:45
↓ 2 callers
Method
launch
* @desc Launch Chrome by finding an acceptable executable on the host system * @param {?ChromeOptions} [options = {}] * @return {Promise<CRI>}
lib/launcher/chrome.js:87
↓ 2 callers
Method
normalizeSeeds
* @desc Ensure the starting seed list is one the frontier can understand * @param {Array<{url:string,mode:string,depth:number}|string>|{url:string,
lib/frontier/helper.js:32
↓ 2 callers
Method
process
* @desc Process discovered outlinks of a page based on the originating seeds configuration * @param {Array<{href: string, pathname: string, host: s
lib/frontier/index.js:113
↓ 2 callers
Method
removeEventListeners
* @desc Remove the listeners registered on an EventEmitter by either {@link addEventListener} or {@link addEventListeners} * @param {!Array<{emitte
lib/crawler/helper.js:49
↓ 2 callers
Method
shouldAddToFrontier
* @desc Determine if a URL should be added to the frontier * @param {Object} url - A URL extracted for the currently visited page * @param {stri
lib/frontier/helper.js:98
↓ 2 callers
Method
shutdown
* @desc Stop crawling and exit * @return {Promise<void>}
lib/crawler/puppeteer.js:217
↓ 2 callers
Function
waitForWSEndpoint
* @desc Function that returns a promise resolving when chrome tells us the WS endpoint is ready * @param chromeProcess * @param timeout * @return {
lib/launcher/chrome.js:267
↓ 2 callers
Method
withAutoClose
* @desc Create a new {@link ChromeCrawler} instance with auto close enabled * @param {CrawlConfig} options - The crawl config for this crawl * @
lib/crawler/chrome.js:426
↓ 1 callers
Method
_initInjects
* @desc Instruct the browsers to inject JavaScript into every page * @return {Promise<void>} * @private
lib/crawler/chrome.js:172
↓ 1 callers
Method
_processSiteMode
(links)
lib/frontier/index.js:142
↓ 1 callers
Method
apndWarcNamePerURL
* @desc Returns a function that creates a WARC filename based on the first URL supplied to returned function * @param {string} outPath * @return
lib/utils/warcNaming.js:58
↓ 1 callers
Function
badExport
* @desc Informs the user that they did not export the correct type of user script * @param {any} exposed
lib/config/index.js:30
↓ 1 callers
Function
badExport
* @desc Informs the user that they did not export the correct type of user script * @param {any} exposed
lib/config/loader.js:32
↓ 1 callers
Function
chromeDesktops
* @desc Executes the ls command for the supplied path looking for .desktop files for Chrome or Chromium * @param {string} desktopPath * @returns {Pr
lib/launcher/chromeFinder.js:58
↓ 1 callers
Function
chromeRunner
* @desc Launches a crawl using the supplied configuration file path * @param {CrawlConfig} conf - The crawl config for this crawl * @return {Promise
lib/runners/chromeRunner.js:28
↓ 1 callers
Method
crawledURL
* @desc Decreases the number of URLs left to crawl for this seed
lib/frontier/seedTracker.js:72
↓ 1 callers
Function
desktopExePath
* @desc Extracts the Chrome or Chromium executable path from the .desktop file * @param {string} desktopPath * @returns {Promise<string[]>}
lib/launcher/chromeFinder.js:70
↓ 1 callers
Method
didNavigate
* @desc Indicate that the browser has navigated to the current URL
lib/crawler/navigationMan.js:165
↓ 1 callers
Method
enableAutoClose
* @desc Enable auto closing of the connection to the remote browser * @return {ChromeCrawler} * @private
lib/crawler/chrome.js:386
↓ 1 callers
Method
ensureScript
* @desc Load the user supplied script (if it exists) and perform validation of it * @param {?string} scriptP - The path to the user script * @re
lib/config/index.js:121
↓ 1 callers
Method
ensureScript
* @desc Load the user supplied script (if it exists) and perform validation of it * @param {string} scriptP - The path to the user script * @ret
lib/config/loader.js:130
↓ 1 callers
Method
ensureSeeds
* @desc Normalizes the supplied seeds. If it value of the seeds field is a string loads the seeds from the file * @param {string | string[]} seeds
lib/config/index.js:176
↓ 1 callers
Method
ensureSeeds
* @desc Normalizes the supplied seeds. If it value of the seeds field is a string loads the seeds from the file * @param {string | string[]} seeds
lib/config/loader.js:186
↓ 1 callers
Method
findChromeDarwin
* @desc Finds an acceptable Chrome or Chromium executable on MacOS * If one is not found throws * @throws Error - If an acceptable executable wa
lib/launcher/chromeFinder.js:207
↓ 1 callers
Method
findChromeLinux
* @desc Finds an acceptable Chrome or Chromium executable on Linux * If one is not found throws * @throws Error - If an acceptable executable wa
lib/launcher/chromeFinder.js:137
↓ 1 callers
Method
findChromeWindows
* @desc Finds an acceptable Chrome or Chromium executable on Windows * If one is not found throws * @throws Error - If an acceptable executable
lib/launcher/chromeFinder.js:287
↓ 1 callers
Function
findPageToConnectTo
* @desc Attempts to find an accible target (page) to connect to in an already launched chrome instance * @param {ChromeOptions} options * @return {P
lib/launcher/puppeteer.js:26
↓ 1 callers
Method
finished
* @desc Called once child frame outlink collection is complete. Collects the top frames outlinks and * resolves the Promise that is being awaited
lib/injectManager/pageInjects/collectLinks.js:236
↓ 1 callers
Method
genWARCForPage
(outlinks)
lib/crawler/chrome.js:280
↓ 1 callers
Method
genWARCForPage
(outlinks)
lib/crawler/puppeteer.js:278
↓ 1 callers
Method
genWarc
* @desc Generate the WARC file * @param {!Object} warcInfo - WARC record information * @property {!string} outlinks - Pre-formatted str
lib/crawler/chrome.js:258
↓ 1 callers
Method
genWarc
* @desc Generate the WARC file * @param {Object} warcInfo - WARC record information * @property {!string} outlinks - Pre-formatted stri
lib/crawler/puppeteer.js:256
↓ 1 callers
Method
getCollectInject
* @desc Receive param object for JS injected into every frame of the page crawled that sets up out link collection * @see https://chromedevtools.gi
lib/injectManager/index.js:70
↓ 1 callers
Method
getNoNaughtyJsInject
* @desc Receive param object for JS injected into every frame of the page crawled that includes disabling things that can act as an crawler trap *
lib/injectManager/index.js:85
↓ 1 callers
Method
getOutLinks
* @desc Retrieve the page's meta information * @return {Promise<{outlinks: string, links: string[], location: string}, Error>}
lib/crawler/chrome.js:346
↓ 1 callers
Method
getOutLinks
* @desc Retrieve the page's meta information * @return {Promise<{outlinks: string, links: Array<{href: string, pathname: string, host: string}>, lo
lib/crawler/puppeteer.js:323
↓ 1 callers
Method
getOutlinks
* @desc Collects the outlink information for a frame * @return {{outlinks: string, links: Array<string>, location: string}}
lib/injectManager/pageInjects/collectLinks.js:107
↓ 1 callers
Method
getUserAgent
* @desc Retrieve the browsers user-agent string * @return {Promise<string>}
lib/crawler/chrome.js:355
↓ 1 callers
Method
getUserAgent
* @desc Retrieve the browsers user-agent string * @return {!Promise<string>}
lib/crawler/puppeteer.js:348
↓ 1 callers
Method
go
* @desc Send the `outlinkcollect` message to all child frames and start the collection timeout
lib/injectManager/pageInjects/collectLinks.js:195
↓ 1 callers
Method
idlePromise
* @desc Start monitoring the network and receive a Promise that resolves once network idle occurred or the global wait time has been reached * @par
lib/crawler/netIdleWatcher.js:105
↓ 1 callers
Method
init
* @desc Setup the crawler
lib/crawler/puppeteer.js:114
↓ 1 callers
Method
initWARC
* @desc Initialize the WARC writter for writting a new WARC * @param {string} warcPath - the path to the new WARC * @param {Object} [o
lib/crawler/chrome.js:236
↓ 1 callers
Method
initWARC
* @desc Initialize the WARC writter for writting a new WARC * @param {string} warcPath - the path to the new WARC * @param {Object} [o
lib/crawler/puppeteer.js:231
↓ 1 callers
Method
load
* * @param {string} confPath * @return {Promise<Object>}
lib/config/loader.js:68
↓ 1 callers
Method
loadingFinished
* @desc Indicate that a request has finished for the RequestHandler#navMan * @param {Object} info
lib/crawler/chrome.js:48
↓ 1 callers
Method
navigate
* @desc Navigate the browser to the URL of the page to be crawled * @param {string} url * @returns {Promise<boolean>}
lib/crawler/puppeteer.js:144
↓ 1 callers
Function
notAsync
* @desc Informs the user that they did not export an async function * @param {any} notAsyncFn
lib/config/index.js:43
↓ 1 callers
Function
notAsync
* @desc Informs the user that they did not export an async function * @param {any} notAsyncFn
lib/config/loader.js:45
↓ 1 callers
Method
prWhenDone
* @desc Returns a promise that resolves once outlink collection, from top frame and child frames is complete * @return {Promise<{outlinks: string
lib/injectManager/pageInjects/collectLinks.js:186
↓ 1 callers
Function
puppeteerRunner
* @desc Launches a crawl using the supplied configuration file path * @param {CrawlConfig} conf - The crawl config for this crawl * @return {Promise
lib/runners/puppeteerRunner.js:27
↓ 1 callers
Method
rawOutLinks
* @desc Receive the raw function that is used to collect outlines from each of the pages frames. Used by {@link PuppeteerCrawler} * @return {outLin
lib/injectManager/index.js:61
↓ 1 callers
Method
rawScoll
* @desc Receive the raw scroll page function for use with Runtime.evaluate * @see https://chromedevtools.github.io/devtools-protocol/tot/Runtime#me
lib/injectManager/index.js:35
↓ 1 callers
Method
reqFinished
* @desc Indicate that a request has finished * @param {Object} info - CDP Response object received by Network.responseReceived or Network.loadingFa
lib/crawler/navigationMan.js:153
↓ 1 callers
Method
reqStarted
* @desc Indicate that a request was made * @param {Object} info - CDP object received from Network.requestWillBeSent * @see https://chromedevtoo
lib/crawler/navigationMan.js:137
↓ 1 callers
Method
requestWillBeSent
(info)
lib/crawler/chrome.js:54
↓ 1 callers
Function
runPromise
* @desc Runs a promise using the supplied thener and catcher functions * @param {function()|Promise} runnable The promise or async / promise returnin
lib/utils/promises.js:44
↓ 1 callers
Method
runUserScript
* @desc If the user supplied a script that scrip is executed or if non was supplied just scroll the page * @return {Promise<void>}
lib/crawler/puppeteer.js:171
↓ 1 callers
Method
shouldAddToFrontierDefault
* @desc Should a discovered URL be added to the frontier using the default strategy, applies for page-only and page-all-links * @param {Object} url
lib/frontier/helper.js:130
↓ 1 callers
Method
shouldAddToFrontierPSD
* @desc Should a discovered URL be added to the frontier using the Page Same Domain strategy * @param {Object} url - A URL extracted for the curre
lib/frontier/helper.js:112
↓ 1 callers
Function
shouldIgnore
(test)
lib/injectManager/pageInjects/collectLinks.js:325
↓ 1 callers
Method
shouldIgnore
* @desc Determines if the supplied URL is to be ignored or not * @param {string} test - A URL * @return {boolean}
lib/injectManager/pageInjects/collectLinks.js:83
↓ 1 callers
Method
start
* @desc Setup the necessary listeners
lib/crawler/netIdleWatcher.js:116
↓ 1 callers
Method
startedNav
* @desc Start Timers For Navigation Monitoring * @param {string} curl the URL browser is navigating to
lib/crawler/navigationMan.js:124
↓ 1 callers
Method
stop
* @desc Stop the page loading and stop capturing requests * @return {Promise<void>}
lib/crawler/chrome.js:215
↓ 1 callers
Method
suppliedWarcName
* @desc Returns a function that provides the full path to WARC file being written to * @param {string} outPath the full path to the WARC file outp
lib/utils/warcNaming.js:48
↓ 1 callers
Function
usrFNGood
* @desc Informs the user that the user script is good
lib/config/index.js:54
↓ 1 callers
Function
usrFNGood
* @desc Informs the user that the user script is good
lib/config/loader.js:56
next →
1–100 of 175, ranked by callers