LMO
LMO

Reputation: 21

Monaco-editor: disable all suggestions

I am using Monaco to edit plain text and I want to disable all kind of suggestions. I disabled all suggestions options. However, when I press "CTRL + Space", monaco is still showing a popup with a message "No suggestions". See an example at https://codesandbox.io/s/monaco-suggestions-issue-hq1j9

screenshot of suggestions

Does anyone know how can I disable this tooltip?

Upvotes: 2

Views: 1743

Answers (1)

waterstopper
waterstopper

Reputation: 588

add this code after assigning this.editor in LanguageTextInput.componentDidMount to override the command:

this.editor.addCommand(Monaco.KeyMod.CtrlCmd | Monaco.KeyCode.Space, function() {
    // you can add some functionality here for this key combination
});

Now when you press Ctrl+Space nothing happens.

Upvotes: 0

Related Questions