refactor merge conflicts bundle to reduce side effects
This commit is contained in:
parent
94d5dd3b7b
commit
c62fe6a293
|
@ -12,7 +12,7 @@ import './components/inline_conflict_lines';
|
|||
import './components/parallel_conflict_lines';
|
||||
import syntaxHighlight from '../syntax_highlight';
|
||||
|
||||
$(() => {
|
||||
export default function initMergeConflicts() {
|
||||
const INTERACTIVE_RESOLVE_MODE = 'interactive';
|
||||
const conflictsEl = document.querySelector('#conflicts');
|
||||
const mergeConflictsStore = gl.mergeConflicts.mergeConflictsStore;
|
||||
|
@ -91,4 +91,4 @@ $(() => {
|
|||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
import initSidebarBundle from '~/sidebar/sidebar_bundle';
|
||||
import '~/merge_conflicts/merge_conflicts_bundle';
|
||||
import initMergeConflicts from '~/merge_conflicts/merge_conflicts_bundle';
|
||||
|
||||
document.addEventListener('DOMContentLoaded', initSidebarBundle);
|
||||
document.addEventListener('DOMContentLoaded', () => {
|
||||
initSidebarBundle();
|
||||
initMergeConflicts();
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue