I'm using a text editor called Atom. When I start a new line by pressing enter, the editor automatically adds a space; which I don't need. Can anyone help? Thanks.


Figuring out the cause

To know what's triggered when pressing enter, you can enable the Key Binding Resolver through the command palette or by pressing Ctrl + . (dot key):

Key binding resolver in the command palette

It should bring a new pane at the bottom of the editor which shows the last input from the keyboard and lists all the triggered actions in order.

Key binding resolver resolving enter as an example

From there, you can pinpoint the plugin which may do what you don't want.

Fix the problem

  • disable the culprit plugin
  • disable this plugin keybindings and implement your own inside your personal keymap.cson file.

    Here's a part of my keymap.cson which swaps docblockr commands.

      # docblockr keybindings
      'tab': 'docblockr:parse-tab'
      'enter': 'docblockr:parse-inline'
      'shift-enter': 'docblockr:parse-enter'
  • sometimes, after a plugin update, rebooting Atom or just reloading the window with Alt+Ctrl+r fixes keybinding problems.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.