We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a1a3fe1 commit 48e1e0fCopy full SHA for 48e1e0f
src/monaco/Monaco.vue
@@ -105,6 +105,22 @@ onMounted(async () => {
105
})
106
editor.value = editorInstance
107
108
+ // Support for go to definition
109
+ monaco.editor.registerEditorOpener({
110
+ openCodeEditor(_, resource) {
111
+ const path = resource.path
112
+ if (/^\//.test(path) && !/^\/node_modules/.test(path)) {
113
+ const fileName = path.replace('/', '')
114
+ if (fileName !== store.state.activeFile.filename) {
115
+ store.setActive(fileName)
116
+ return true
117
+ }
118
119
+
120
+ return false
121
122
+ })
123
124
// Support for semantic highlighting
125
const t = (editorInstance as any)._themeService._theme
126
t.getTokenStyleMetadata = (
0 commit comments