Closed qingyuun closed 4 years ago
There is no such thing in prettier. ref: https://github.com/prettier/prettier/issues/1139 However, this should be possible with eslint https://eslint.org/docs/rules/space-before-function-parentheses
Edit: It's https://eslint.org/docs/rules/space-before-function-paren the other one is deprecated and doesn't work
Such a situation occurred when I upgraded from 1.0.1 to 1.1.0. I'm using eslint and standard JS style. In 1.1.0 prettier ignores this rule. I rolled back to 1.0.1 and all was well.
Here is a link to 1.0.1 https://esbenp.gallery.vsassets.io/_apis/public/gallery/publisher/esbenp/extension/prettier-vscode/1.0.1/assetbyname/Microsoft.VisualStudio.Services.VSIXPackage
After downloading, rename the extension from vsixpackage to vsix and install
Did the extension stop using prettier-eslint
entirely, or was it just one rule?
I think it is this issue. https://github.com/prettier/prettier-eslint/issues/156
@CiGit Maybe bump prettier-eslint
and release a new version?
@azz Not quite understand the question. You say that this problem is related to an outdated version prettier-eslint?
Yeah, this extension bundles in prettier-eslint
(which it uses when prettier.eslintIntegration
is true
). I suspect the issue your facing is a consequence of the aforementioned issue. You could try npm install prettier-eslint@latest
and it might work.
@azz No, out. Probably not the problem. I have installed the latest prettier-eslint 8.7.5 and still is ignoring the rules
Will update prettier-eslint, but there was no change between 1.0.1 and 1.1.0 ...
@antonreshetov you have to update it in the extension itself, we don't pick your local version.
Isn't it an issue between eslint 3 and eslint 4 ? The rule is named space-before-function-paren in v4. Bundled version is also an eslint@4 in 1.0.1
Just released version 1.1.1
I updated to 1.1.1, the result is now somewhat deteriorated
What's wrong? Can you post a before / after text please :-)
Briefly, again not working correctly https://eslint.org/docs/rules/space-before-function-parentheses
This rule was removed in ESLint v1.0 and replaced by the space-before-function-paren rule
Hey, I'm still having this issue.
No matter what I do regardless of the rule I have set in my .eslintrc.js
I can't seem to get prettier to add the space between function and parenthesis.
I am totally up to date with both ESLint and Prettier and have the "Prettier: Eslint Integration" enabled.
I end up with a situation, that when I format document it ends up spitting ESLint errors, because there's no space between function name and parenthesis.
This is after a Format Document
command
@Spittal Were you able to resolve this issue?
Not yet, sorry. @mike1e
any update?
same issue. is there a workaround ?
Hello,
this bug is really annoying. What prevents it from resolving this issue?
Thank you
Jan Opravil
Still an issue, this is very annoying! Why is commenting on the issue ? :/
Due to the huge amount of bugs, linting support has been deprecated in version 2.0.0. See the documentation on the recommended configuration: https://github.com/prettier/prettier-vscode#vscode-eslint-and-tslint-integration
See #870 for more details.
FYI the equivalent of space-before-function-paren is supported by my prettierx
fork.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
I want to add a space between the JS method function name and the parenthesis. how to set it?