mirror of
https://github.com/laurent22/joplin.git
synced 2024-12-24 10:27:10 +02:00
Removes unnecessary trivial dependencies that causes re-rendering (#6471)
This commit is contained in:
parent
443e049022
commit
2dedede5c3
@ -859,8 +859,6 @@ const mapStateToProps = (state: AppState) => {
|
||||
return {
|
||||
themeId: state.settings.theme,
|
||||
settingEditorCodeView: state.settings['editor.codeView'],
|
||||
folders: state.folders,
|
||||
notes: state.notes,
|
||||
hasDisabledSyncItems: state.hasDisabledSyncItems,
|
||||
hasDisabledEncryptionItems: state.hasDisabledEncryptionItems,
|
||||
showMissingMasterKeyMessage: showMissingMasterKeyMessage(syncInfo, state.notLoadedMasterKeys),
|
||||
|
@ -259,7 +259,7 @@ function CodeMirror(props: NoteBodyEditorProps, ref: any) {
|
||||
return commandOutput;
|
||||
},
|
||||
};
|
||||
}, [props.content, props.visiblePanes, addListItem, wrapSelectionWithStrings, setEditorPercentScroll, setViewerPercentScroll, resetScroll, renderedBody]);
|
||||
}, [props.content, props.visiblePanes, addListItem, wrapSelectionWithStrings, setEditorPercentScroll, setViewerPercentScroll, resetScroll]);
|
||||
|
||||
const onEditorPaste = useCallback(async (event: any = null) => {
|
||||
const resourceMds = await handlePasteEvent(event);
|
||||
|
@ -585,7 +585,6 @@ const mapStateToProps = (state: AppState) => {
|
||||
return {
|
||||
noteId: noteId,
|
||||
notes: state.notes,
|
||||
folders: state.folders,
|
||||
selectedNoteIds: state.selectedNoteIds,
|
||||
selectedFolderId: state.selectedFolderId,
|
||||
isProvisional: state.provisionalNoteIds.includes(noteId),
|
||||
|
@ -27,7 +27,6 @@ export interface NoteEditorProps {
|
||||
editorNoteStatuses: any;
|
||||
syncStarted: boolean;
|
||||
bodyEditor: string;
|
||||
folders: any[];
|
||||
notesParentType: string;
|
||||
selectedNoteTags: any[];
|
||||
lastEditorScrollPercents: any;
|
||||
|
Loading…
Reference in New Issue
Block a user