Hi
I am using ace-editor in my javascript code. I am using a custom completer for my code. I tried to disable and enable the local autocompleters like (textCompleter, keywordCompleter and SnippetCompleter) based on the scenario. I am changing the editor.completers property for enable/disable the local completers.
Here is some code:
// For removing local autocompleters
completers.forEach(function (compelter) {
editor.completers.splice(editor.completers.indexOf(compelter), 1);
});
// For adding them back to completers list
completers.forEach(function (completer) {
editor.completers.push(completer);
});
But the problem is even I removed the local completers, for the first time,I am getting local keywords in suggestions while I do ctrl+space.
From the second time it is working fine. I could not understand why it is showing local suggestions even I removed them from editor.completers for the first time.
Can anyone please help me to solve this issue
Thanks in Advance
Priyanka