RickStrahl / Westwind.HtmlPackager

A small utility class used to package HTML content into a self contained HTML document both as a single file, or a folder with all dependencies copied to local.
35 stars 9 forks source link

Use append-method instead of "new Uri(BaseUri, url);" #6

Open StefH opened 2 years ago

StefH commented 2 years ago

This fixes the issue when you provide a basePath which is not in the same folder as the htm file, like this:

string packaged = packager.PackageHtml(@"c:\temp\web\github.htm", @"c:\temp\web\GitHub_files");
StefH commented 2 years ago

@RickStrahl Please take a look at this PR.

More details also here: https://stackoverflow.com/questions/372865/path-combine-for-urls