2 ms·
FYI `schemaCompletionSource` exists https://github.com/codemirror/lang-sql#user-content-schemacompletionsource https://github.com/codemirror/lang-sql#user-conte
by AlexErrant 2y ago
FYI `schemaCompletionSource` exists https://github.com/codemirror/lang-sql#user-content-schemacompletionsource https://github.com/codemirror/lang-sql#user-content-schemaco...
But if you want an example of async completion, I do it here
https://github.com/AlexErrant/Pentive/blob/fe86a8a185e4be47045f62bfd47562312546b371/shared-dom/src/language/queryCompletion.ts#L50-L53 https://github.com/AlexErrant/Pentive/blob/fe86a8a185e4be470...
which is called from here
https://github.com/AlexErrant/Pentive/blob/fe86a8a185e4be47045f62bfd47562312546b371/app/src/components/queryEditor.tsx#L200-L205 https://github.com/AlexErrant/Pentive/blob/fe86a8a185e4be470...
Perf isn't really a problem for me since I'm calling SQLite in the browser; it's maybe 10-20ms.