portapack / index / generateRecursivePortableHTML
Function: generateRecursivePortableHTML()
generateRecursivePortableHTML(
url
,depth
?,options
?,loggerInstance
?):Promise
<BuildResult
>
Defined in: index.ts:141
Recursively crawl a remote website starting from a URL and bundle it. If loggerInstance
is not provided, it creates its own logger based on options.logLevel
.
Parameters
url
string
The starting URL (must be http/https).
depth?
number
= 1
Maximum recursion depth (0 for only the entry page, 1 for entry + links, etc.).
options?
BundleOptions
= {}
Configuration options.
loggerInstance?
Optional external logger instance.
Returns
Promise
<BuildResult
>
A Promise resolving to the build result containing the multi-page bundled HTML.
Throws
Errors during network fetching, parsing, or bundling.