How to config intellij-idea not format some part of the code?

后端 未结 4 1284
借酒劲吻你
借酒劲吻你 2021-02-05 00:54

In a html file, there is some code used custom template-language:



        
4条回答
  •  花落未央
    2021-02-05 01:32

    In my version EAP 13.1, you must enable the following option in settings,

    Preferences -> Code Style -> General -> Formatter Control -> Enable formatter markers in comments

    before you can use these comments,

    // @formatter:off
    
    // @formatter:on 
    

    or these (depending on language):

    
    
    
    

    Screenshot:

    Screenshot highlighting the checkbox for Enable formatter markers in comments under Preferences

提交回复
热议问题