Eslint-plugin-react: jsx-indent-props for aligned indentation

Created on 17 Jan 2016  路  2Comments  路  Source: yannickcr/eslint-plugin-react

It would be nice if this rule would allow to set an option to lint all the props declarations one below the other just like the next snippet shows.

<div styleName='content'>
  <TableOfContents content={props.model.tableOfContents} />
    <ContentView content={props.model.contents}
                 editing={props.model.editing}
                 actions={props.actions}
                 bind={this.props.bind} />
</div>
enhancement help wanted rule

Most helpful comment

I'm going to delete these 4 +1 comments, and any further ones - please follow GitHub etiquette and express that emotion with a reaction on the original post. Thanks!

All 2 comments

I'm going to delete these 4 +1 comments, and any further ones - please follow GitHub etiquette and express that emotion with a reaction on the original post. Thanks!

Currently such indentation is default one in WebStorm - it's clear and convenient.

Really want to have rule config like

'react/jsx-indent-props': [2, 2],

and for example

'react/jsx-indent-props': [2, 'tag-name'],
Was this page helpful?
0 / 5 - 0 ratings