Update schema for new attribute: enable_auto_import
This commit is contained in:
parent
b33d44b82c
commit
83db909715
2 changed files with 9 additions and 0 deletions
|
@ -60,6 +60,11 @@
|
|||
"description": "Use snippets when completing procedures—adds parenthesis after the name.",
|
||||
"default": true
|
||||
},
|
||||
"enable_auto_import": {
|
||||
"type": "boolean",
|
||||
"description": "Automatically import packages that aren't in your import on completion",
|
||||
"default": true
|
||||
},
|
||||
"enable_references": { "type": "boolean" },
|
||||
"enable_fake_methods": {
|
||||
"type": "boolean",
|
||||
|
|
|
@ -1700,6 +1700,10 @@ append_non_imported_packages :: proc(
|
|||
position_context: ^DocumentPositionContext,
|
||||
items: ^[dynamic]CompletionItem,
|
||||
) {
|
||||
if !common.config.enable_auto_import {
|
||||
return
|
||||
}
|
||||
|
||||
for collection, pkgs in build_cache.pkg_aliases {
|
||||
//Right now only do it for core
|
||||
if collection != "core" {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue