0

I haven't found any good resources for this, so here's the question. I have the following code:

public function myFunction(
    string $name,
    int $age
) {}

When I format the code, PhpStorm will align the variables like so:

public function myFunction(
    string $name,
    int    $age
) {}

I want to STOP this behaviour and have it format the code like the first block. Running build #PS-213.7172.28 in case that matters.

0

1 Answer 1

1

If I'm getting this correctly: it is introduced by WI-59669 in PhpStorm 2021.2.3.

Here is a WI-61085 ticket that asks to have such double alignment (by both type and parameter name) optional -- watch it (star/vote/comment) to get notified with any progress.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.