add ability to use svgs
This commit is contained in:
parent
99df998e11
commit
aae72ea57d
1 changed files with 1 additions and 1 deletions
|
@ -174,7 +174,7 @@ class PreviewFrame extends React.Component {
|
|||
this.props.jsFiles.forEach(jsFile => {
|
||||
const newJSFile = { ...jsFile };
|
||||
let jsFileStrings = newJSFile.content.match(/(['"])((\\\1|.)*?)\1/gm);
|
||||
const jsFileRegex = /^('|")(?!(http:\/\/|https:\/\/)).*\.(png|jpg|jpeg|gif|bmp|mp3|wav|aiff|ogg|json|txt|csv)('|")$/i;
|
||||
const jsFileRegex = /^('|")(?!(http:\/\/|https:\/\/)).*\.(png|jpg|jpeg|gif|bmp|mp3|wav|aiff|ogg|json|txt|csv|svg)('|")$/i;
|
||||
jsFileStrings = jsFileStrings || [];
|
||||
jsFileStrings.forEach(jsFileString => {
|
||||
if (jsFileString.match(jsFileRegex)) {
|
||||
|
|
Loading…
Reference in a new issue