We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c3a0a49 commit dba6d7eCopy full SHA for dba6d7e
1 file changed
packages/editor-codemirror/src/behaviors/completion.ts
@@ -225,12 +225,15 @@ async function getCompletions(
225
const token = context.matchBefore(/\S+/)?.text;
226
227
const filteredItems = items.filter(item => {
228
+ // no namespaces
229
+ if (vsKindToType(item.kind) === 'namespace') return false;
230
+
231
// no text completions that aren't snippets
232
if (item.kind === CompletionItemKind.Text &&
233
item.insertTextFormat !== InsertTextFormat.Snippet) return false;
234
235
// only allow non-text edits if we have no token
- if (!item.textEdit && token) return false;
236
+ if (item.textEdit === undefined && token) return false;
237
238
// require at least inclusion
239
const replaceText = getReplaceText(context, item).toLowerCase();
0 commit comments