-
Notifications
You must be signed in to change notification settings - Fork 44
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
Default glob pattern like standard #35
Comments
Unfortunately this would also make it harde to discover |
Isn't that pretty common across most unix tools? (that usage info is only printed when Without dismissing the value of discoverability, the help output is only useful for people on their first-ever run; likely just poking around. Every invocation after that, they're intending to actually run the formatter. This should be optimized for the 90% use case (which is actually running the formatter), not the .1% use case of getting help. (Which is already conventionally available via
|
Are you open for a PR on this? Would bring standard and prettier-standard much closer. |
I'd rather prettier-standard operate more similar to prettier than standard |
I have a lot of thoughts on this, I might try to compile them into a blog post..
Thing is, if you use prettier-standard, you don't need prettier anymore. But you still need linting. So you have to use both prettier-standard and standard. But they both have different API and different configuration. Prettier itself doesn't have that problem, because people using prettier generally don't use standard, so the compatibility there is not important. Arguably, they're just different tools (one's formatter, one's linter), so they don't have to work the same. I'm just trying to think of a best way to combine them (prettier and standard), which I thought this tool (prettier-standard) does, but really it's just a specific variant of prettier rather than combination. Out of curiosity, when you use prettier-standard, do you also use standard? Or eslint? Or something else? |
I'm using prettier-standard and separately eslint with following config:
I think ideally prettier-standard would become a fork of prettier with less configuration flags and standard compatibility that is now being rejected from prettier: prettier/prettier#5723 Additionally it could have
|
Yes, Should this issue be closed then (although I still agree with OP, default glob would be sweet, or at least configurable)? And |
Yes, I'll close this issue. The problem is Unix tools don't change anything by default and prettier-standard would automatically format all .js files if I made this a default, which can be annoying. The |
I also have mixed opinions. I like both standard and prettier (and prettier-standard) because of the overarching philosophies to eliminate or reduce configuration, which eliminates bike-shedding. In general, I'm pro convention over configuration, so I very much appreciate standard's default CLI behavior. As a standard user, I also rather expected prettier-standard to be philosophically in-line with standard and to be more convention driven. However, I also see the argument that prettier-standard is really a replacement for prettier, and so it should be as near a drop-in replacement as possible. (And keeping a similar-behaving CLI reduces friction when/if people switch.) And while most invocations of prettier-standard would be within a VC repository, thus making "oops" invocations revertible; I also appreciate the desire to not have "mutate files" be the default if ever invoked outside VC. 👍 |
Would love to have prettier-standard use the same default glob pattern as standard itself:
This would make running
prettier-standard
operate similar tostandard
(no options necessary, just normal conventional configuration by default)The text was updated successfully, but these errors were encountered: