You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 8, 2020. It is now read-only.
The following function assumes my SVG image file is a webfont before it is served by the development server. Took a couple hours to debug. The SVG file needs to be investigated further in the test to determine if it's actually a font or an image.
Task_ContentType.prototype.duty=function(framework,callback){varself=this;framework.files.forEach(function(cF){cF.contentType=(self.contentTypes[cF.getFileExtension()]) ? self.contentTypes[cF.getFileExtension()] : 'text/plain';switch(true){// This isWebfont() test will assume all SVG files are web fonts!// This detection is incorrect and prevents all SVG files from being served on the development servercase(cF.isWebfont()):
cF.requestPath='theme/'+cF.getBaseName()+cF.getFileExtension();break;case(cF.isImage()):
cF.requestPath='theme/images/'+cF.getBaseName()+cF.getFileExtension();break;case(cF.isStylesheet()):
cF.requestPath='theme/'+cF.getBaseName()+cF.getFileExtension();cF.contentType="text/css; charset=utf-8";break;case(cF.isHTML()):
cF.requestPath=cF.getBaseName()+cF.getFileExtension();break;default:
cF.requestPath=cF.getBaseName()+cF.getFileExtension();break;}});
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The following function assumes my SVG image file is a webfont before it is served by the development server. Took a couple hours to debug. The SVG file needs to be investigated further in the test to determine if it's actually a font or an image.
The text was updated successfully, but these errors were encountered: