How to auto-indent code in the Atom editor?

后端 未结 11 1486
野的像风
野的像风 2020-12-07 07:04

How do you auto-indent your code in the Atom editor? In other editors you can usually select some code and auto-indent it.

Is there a keyboard shortcut as well?

11条回答
  •  南方客
    南方客 (楼主)
    2020-12-07 07:20

    This works for me:

    'atom-workspace atom-text-editor':
        'ctrl-alt-a': 'editor:auto-indent'
    

    You have to select all with ctrl-a first.

提交回复
热议问题