ioioioioioioi
V2EX  ›  问与答

谁记得实现等号对齐的 sublime text 插件的名称叫什么?

  •  
  •   ioioioioioioi · Jan 6, 2017 · 6048 views
    This topic created in 3458 days ago, the information mentioned may be changed or developed.
    'country_name' => input(''),
    'company_name' => input(''),
    'company_id' => input(''),
    'job_title' => input(''),
    

    等号对其如下

    'country_name'  => input(''),
    'company_name'  => input(''),
    'company_id'    => input(''),
    'job_title'     => input(''),
    

    找到了,是alignment

    7 replies    2017-01-06 11:41:10 +08:00
    hanzichi
        1
    hanzichi  
       Jan 6, 2017   ❤️ 2
    alignment
    hanzichi
        2
    hanzichi  
       Jan 6, 2017
    ioioioioioioi
        3
    ioioioioioioi  
    OP
       Jan 6, 2017
    @hanzichi 刚装了 alignment , 没反应是怎么回事?
    ~~~~
    [
    { "keys": ["alt+z"], "command": "alignment" }
    ]
    hanzichi
        4
    hanzichi  
       Jan 6, 2017
    @ioioioioioioi 没选中代码?或者 alt+z 快捷键冲突了?
    hanzichi
        5
    hanzichi  
       Jan 6, 2017
    @ioioioioioioi 重启下 sublime ?
    ioioioioioioi
        6
    ioioioioioioi  
    OP
       Jan 6, 2017
    @hanzichi 搞定了,多谢。在 setting 里加了"alignment_chars": ["=", ":", "=>"]
    loserwn
        7
    loserwn  
       Jan 6, 2017
    @ioioioioioioi 原则上默认的配置中应该支持 => 吧。

    ```bash
    // The characters to align along with "alignment_chars"
    // For instance if the = is to be aligned, there are a number of
    // symbols that can be combined with the = to make an operator, and all
    // of those must be kept next to the = for the operator to be parsed
    "alignment_prefix_chars": [
    "+", "-", "&", "|", "<", ">", "!", "~", "%", "/", "*", "."
    ]
    ```
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5749 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 44ms · UTC 06:25 · PVG 14:25 · LAX 23:25 · JFK 02:25
    ♥ Do have faith in what you're doing.