mirror of https://github.com/laurent22/joplin.git
Avoid running js when empty
parent
39d3319252
commit
19194c9a23
|
@ -440,7 +440,9 @@ function NoteEditor(props: Props, ref: any) {
|
|||
isFirstScrollRef.current = false;
|
||||
return;
|
||||
}
|
||||
webviewRef.current?.injectJS(jumpToHashJs);
|
||||
if (jumpToHashJs && webviewRef.current) {
|
||||
webviewRef.current.injectJS(jumpToHashJs);
|
||||
}
|
||||
}, [jumpToHashJs]);
|
||||
|
||||
const html = useHtml(css);
|
||||
|
|
Loading…
Reference in New Issue