Skip to content

Commit 5989706

Browse files
autocompleteConfig --> autocomplete
1 parent 037a7a0 commit 5989706

File tree

5 files changed

+7
-9
lines changed

5 files changed

+7
-9
lines changed

analysis/src/CompletionBackEnd.ml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1137,9 +1137,7 @@ and getCompletionsForContextPath ~debug ~full ~opens ~rawOpens ~pos ~env ~exact
11371137
in
11381138

11391139
let globallyConfiguredCompletionsForType =
1140-
match
1141-
package.autocompleteConfig |> Misc.StringMap.find_opt mainTypeId
1142-
with
1140+
match package.autocomplete |> Misc.StringMap.find_opt mainTypeId with
11431141
| None -> []
11441142
| Some completionPaths ->
11451143
completionPaths |> List.map (fun p -> String.split_on_char '.' p)

analysis/src/Packages.ml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,10 +66,10 @@ let newBsPackage ~rootPath =
6666
| _ -> None)
6767
| None -> None
6868
in
69-
let autocompleteConfig =
69+
let autocomplete =
7070
match config |> Json.get "editor" with
7171
| Some editorConfig -> (
72-
match editorConfig |> Json.get "autocompleteConfig" with
72+
match editorConfig |> Json.get "autocomplete" with
7373
| Some (Object map) ->
7474
map
7575
|> List.fold_left
@@ -180,7 +180,7 @@ let newBsPackage ~rootPath =
180180
opens;
181181
namespace;
182182
uncurried;
183-
autocompleteConfig;
183+
autocomplete;
184184
}))
185185
| None -> None
186186
in

analysis/src/SharedTypes.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,7 @@ type package = {
494494
opens: path list;
495495
uncurried: bool;
496496
rescriptVersion: int * int;
497-
autocompleteConfig: file list Misc.StringMap.t;
497+
autocomplete: file list Misc.StringMap.t;
498498
}
499499

500500
let allFilesInPackage package =

docs/docson/build-schema.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@
353353
"editor": {
354354
"type": "object",
355355
"properties": {
356-
"autocompleteConfig": {
356+
"autocomplete": {
357357
"type": "object",
358358
"description": "A mapping to extend the autocompletion for a given type with an array of modules. E.g. `{ \"int\": [\"IntUtils\", \"IntExt\"] }` will extend the autocompletion of the `int` type with the values from `IntUtils` and `IntExt` modules.",
359359
"patternProperties": {

tests/analysis_tests/tests/rescript.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"jsx": { "version": 4 },
1515
"suffix": ".res.js",
1616
"editor": {
17-
"autocompleteConfig": {
17+
"autocomplete": {
1818
"array": ["ArrayUtils"],
1919
"Fastify.t": ["FastifyExt"]
2020
}

0 commit comments

Comments
 (0)