Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@smarterlabs/site-downloader

ken85rose1MIT0.0.4

Converts any website into a static site. Minimal changes are made to ensure pages can still render staticly.

readme

@smarterlabs/site-downloader

Converts any website into a static site. Minimal changes are made to ensure pages can still render staticly.

Usage

const siteDownloader = require(`@smarterlabs/site-downloader`)

siteDownloader({

    // Sitemaps to be parsed for page locations
    entry: [
        `https://originsite.com/sitemap.xml`,
    ],


    // Add domains here to also crawl assets from other locations when encountered, useful for CDNs
    domains: [
        { domain: `originsite.com`, path: `/` },
        { domain: `assets.cdn.com`, path: `/assets` },
    ],

    // Output directory
    dist: `dist`,
})