Skip to content

Commit c44c5f0

Browse files
committed
fix: fix html scripts errors.
1 parent 327754d commit c44c5f0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export default React.forwardRef<HTMLIFrameElement, RunWebProps>((props, ref) =>
1313
const srcDoc = useMemo(() => {
1414
const jsString = js ? `<script type="text/javascript">${js}</script>` : '';
1515
const cssString = css ? `<style>${css}</style>` : '';
16-
return `<!DOCTYPE html><html><head>${cssString}</head><body>${html}${jsString}</body></html>`;
16+
return `<!DOCTYPE html><html><head>${cssString}</head><body>${html}</body>${jsString}</html>`;
1717
}, [css, html, js]);
1818

1919
return <iframe title={title} width="100%" height="100%" style={{ border: 0 }} {...other} ref={ref} srcDoc={srcDoc} />;

0 commit comments

Comments
 (0)