gildas-lormeau / single-file-cli

CLI tool for saving a faithful copy of a complete web page in a single HTML file (based on SingleFile)
GNU Affero General Public License v3.0
540 stars 58 forks source link

Issue capturing Github urls with browserless #35

Open pawanpaudel93 opened 1 year ago

pawanpaudel93 commented 1 year ago

Issue

When the Browserless endpoint is provided as a browserServer option and a GitHub URL eg. https://github.com/pawanpaudel93, single-file does not capture the URL completely, and when opening the captured webpage the webpage seems to load without CSS.

But, It works perfectly when used without browserless though.

marsk6 commented 7 months ago

I have the same issue with CSS. and I find that all CSS cdn assets have CORS errors.

image

so after appending access-control-allow-origin: {originHost} and access-control-allow-credentials: true into the response header, the captured webpage can work completely.

pawanpaudel93 commented 7 months ago

@marsk6 how are you using the headers withsingle-file-cli and the captured webpage is working completely ? Thanks.