Skip to content

Commit

Permalink
Code scanning - DOM text reinterpreted as HTML #1427
Browse files Browse the repository at this point in the history
URI encode fix
  • Loading branch information
kkrug authored and jdonis committed Sep 18, 2024
1 parent aeee333 commit cc1fa08
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assets/client/src/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const renderPreview = () => (
)

const rootElement = document.getElementById('preview');
const imageBase = rootElement.getAttribute('data-image-base');
const imageBase = encodeURI(rootElement.getAttribute('data-image-base'));
ReactDOM.render(renderPreview(), rootElement);

// If you want your app to work offline and load faster, you can change
Expand Down

0 comments on commit cc1fa08

Please sign in to comment.