roslov / psr12ext

PSR-12 Extended Coding Standard
MIT License
3 stars 1 forks source link

Set exact indentation for ternaries and multiline strings #41

Open roslov opened 6 months ago

roslov commented 6 months ago

By #40, I disabled the exact indentation for ternaries and multiline strings.

But now, we have such a problem:

$where = in_array($cISO, ['PT', 'MX', 'ES', 'IT', 'LV', 'LT', 'DK', 'CH', 'CZ'], true)
        ? ' and cc.is_act=1'
    : ' and cc.is_vis=1';

$string = 'abcdefg'
        . 'abcdefg'
. 'abcdefg'
  . 'abcdefg';

Therefore, we have to find out a way to set the exact indentation for ternaries and multiline strings. Probably there should be written a custom sniff or found an existing one.