Closed feross closed 8 years ago
+1
+1
No Solution yet?
+1
+1
This breaks basically every single component file in a ES6 react project now. :(
class Foo extends React.Component {
componentWillMount () {}
componentDidMount () {}
componentWillReceiveProps () {}
shouldComponentUpdate () {}
componentWillUpdate () {}
componentDidUpdate () {}
componentWillUnmount () {}
render () {}
}
Tagging related bugs: #75, #134, and millermedeiros/esformatter#384
any word on when this will be fixed yet?
@janecakemaster Hi! This package needs some love :) All the maintainers would love to fix it, but we're really busy! A pull request would be lovely!
@feross i'd love to help, is there anything i can read up on to get started? never worked on a package like this before
Thought this issue is related to https://github.com/millermedeiros/esformatter/issues/368.
@janecakemaster Yeah! The package uses esformatter
to actually format the code. You can read about it here: https://www.npmjs.com/package/esformatter
Essentially, we pass it a configuration specifying how we want the code to be formatted and it does it for us. There's been lots of progress on esformatter
since we created standard-format
so there are probably lots of new "rules" we can add to the configuration file to do a better job with formatting.
Happy to add you (or anyone else who is reading this) as a maintainer after one or two good PRs. :smile:
damn that's a lot of configs to go through. i'll take a look in the next week or so when i've got spare time
@janecakemaster Sounds good.
any further updates on this issue?
any updates? I met the same problem.
@hxshandle we are moving towards using the --fix flag provided by eslint directly so we don't have to maintain two rulesets. I believe the latest standard has this already.
This issue is fixed if you use the new formatter: standard --fix
.
Ensure you're using the latest standard
, version 8.0.0. You can check with standard --version
.
Moving from feross/standard. Original issue here: https://github.com/feross/standard/issues/264
With this code:
Format code doesn't work: