question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Indent props aligned to first.

See original GitHub issue

Wishing there was a rule to force indentation of props similar to the parameter indentation by eslint. https://eslint.org/docs/rules/indent#functiondeclaration

My idea would be to have something that looks like this:

<ComponentBlah prop1='stuff'
               prop2='stuff'
               prop3='stuff' />

Am I missing this as an option for an existing rule?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
jseminckcommented, Sep 13, 2017

I don’t think that we have a rule that enforces this style at the moment.

0reactions
sbonamicommented, Jan 24, 2018

@hallaathrad did anything come of this?

Edit: Oh, dupe of https://github.com/yannickcr/eslint-plugin-react/issues/398 it seems. I’ll follow along there!

Read more comments on GitHub >

github_iconTop Results From Across the Web

eslint-plugin-react/jsx-indent-props.md at master - GitHub
The indent mode can be "tab" for tab-based indentation, a positive number for space indentations or "first" for aligning the first prop for...
Read more >
Configuration for rule "react/jsx-indent" is invalid: Value "4 ...
I've arrived at work today to an unusual error coming from my linter package. I've had a look at the documentation for the...
Read more >
indent - ESLint - Pluggable JavaScript Linter
A pluggable and configurable linter tool for identifying and reporting on patterns in JavaScript. Maintain your code quality with ease.
Read more >
text-indent | CSS-Tricks
The text-indent property specifies how much horizontal space text should be moved before the beginning of the first line of the text content ......
Read more >
EditorConfig properties for C#: Tabs, Indents, Alignment
Place comments at the first column when commenting out code. Otherwise, comments will use the indentation level of the commented code. Possible ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found