Skip to content

Kepler.gl is a powerful open source geospatial analysis tool for large-scale data sets.

Fix unable to fetch external stylesheets when taking the screenshot (#187)

Javidaebd171d2c66
diff --git a/src/utils/dom-to-image.js b/src/utils/dom-to-image.js
index 1fafd703f..ab659a117 100644
--- a/src/utils/dom-to-image.js
+++ b/src/utils/dom-to-image.js
@@ -698,7 +698,7 @@ function newFontFaces() {
return Promise.all(
styleSheets.map(sheet => {
if (sheet.href) {
- return fetch(sheet.href)
+ return fetch(sheet.href, {credentials: 'omit'})
.then(toText)
.then(setBaseHref(sheet.href))
.then(toStyleSheet)