-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Doesn't break long React props #15
Comments
And don't forget about this form: const FooForm = ({colour}) => {
const method = 'GET'
return (
<BaseForm {...{
url: '/auth/google',
method, colour
}}/>
)
} |
Similarly, I tested: const render = ({ styles }) => (
<div style={styles} key="something">
Keep the wrapping params. Put each key on it's own line.
</div>
); which results in: const render = ({ styles }) => <div style={
styles
} key="something">
Keep the wrapping params. Put each key on it's own line.
</div>; |
Here, IMO the best style would be the one that optimizes for diff readability on changes. |
I'm going to try to tackle this now. |
The example by @ericclemmons now compiles to: const render = ({ styles }) => <div style={styles} key="something">
Keep the wrapping params. Put each key on it's own line.
</div>; which is an improvement, but I agree the parens should be maintained. I'll open a separate issue for that if one doesn't already exist, and try to tackle soon. (note that improvement is probably unrelated to my modification, I didn't check) |
I am closing this in favour of #73. Please continue the discussion in that thread. |
e.g.
should probably be converted into
The text was updated successfully, but these errors were encountered: