Skip to content

Commit

Permalink
Merge pull request kubetail-org#102 from sherrardb/add-webp-support
Browse files Browse the repository at this point in the history
detect .webp image file extension
  • Loading branch information
amorey authored Dec 1, 2019
2 parents d770660 + b73fe46 commit f4f9eb9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/loadjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ function loadFile(path, callbackFn, args, numTries) {
e.rel = 'preload';
e.as = 'style';
}
} else if (/(^img!|\.(png|gif|jpg|svg)$)/.test(pathname)) {
} else if (/(^img!|\.(png|gif|jpg|svg|webp)$)/.test(pathname)) {
// image
e = doc.createElement('img');
e.src = pathStripped;
Expand Down

0 comments on commit f4f9eb9

Please sign in to comment.