Javascript tab in function call parameter

Hi,

In javascript, i use this code style to call a function:

$.ajax(
{
    type: 'POST',
    url: 'myUrl.php'
    etc....
});

However, if i try this with PhpStorm, it automatically sets a tab before the '{', like this:

$.ajax(
    {
        type: 'POST'


It's  very frustrating - i have to modify the tabs after my code is complete,  and with a copy paste it's of course the same problem. I tried al kinds  of configuration settings, however i could not find it. Is there a  setting for this?

2 comments
Comment actions Permalink

Hi there,

Well ... Settings | Code Style | JavaScript | Tabs and Indents | Continuation indent = 0

I just do not know how it will affect the rest of the code (in other places) ... but this particular one it should solve.

and with a copy paste it's of course the same problem

Settings | Editor | Smart Keys | Reformat on paste = None

0

Please sign in to leave a comment.