Make raw.githubusercontent.com work for css imports
This commit is contained in:
parent
71a60a0359
commit
d0940a8b19
1 changed files with 5 additions and 0 deletions
|
@ -57,6 +57,11 @@ electron.app.whenReady().then(() => {
|
|||
if (responseHeaders) {
|
||||
delete responseHeaders["content-security-policy-report-only"];
|
||||
delete responseHeaders["content-security-policy"];
|
||||
|
||||
// Fix hosts that don't properly set the content type, such as
|
||||
// raw.githubusercontent.com
|
||||
if (url.endsWith(".css"))
|
||||
responseHeaders["content-type"] = ["text/css"];
|
||||
}
|
||||
cb({ cancel: false, responseHeaders });
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue