I am using VS Code to write markdown files. Is there any way to use a wordlist with technical terms, which is stored in a separate folder outside the opened markdown project, for autocompletion?
At the moment the format of the wordlist with all technical terms is a text file which has on each line a particular term. However, it would be possible to reformat this file if necessary.
2
Answers
If you have that wordlist open in your project, I would think that this setting should help:
That should suggest words from all open documents.
Other wise you would probably have to make your extension with a
CompletionProvider
which incorporates your wordlist.You can use the extension Complete from File.
You have to define the languageID and files to use with a configuration in
settings.json
:Each line of the file is used as a possible completion item. The file can contain comments (
//
and#
lines) and empty lines. A completion line can contain any character (including spaces) but the initial characters must be word characters.The default is that you need at least 3 characters to get a completion.
This setting can be changed (
complete-from-file.minimalCharacterCount
).In Markdown files you have to request a completion with:
Trigger Suggest (key:
ctrl+space
, commandID:editor.action.triggerSuggest
)