-
-
Notifications
You must be signed in to change notification settings - Fork 178
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
Not working with PUG template #617
Comments
We need runnable reproduction like codesandbox, GitHub Repository, etc. Not just codes. |
I have added the sandbox to the issue description. As it's my first time with codesandbox, I hope it is configured correctly, if not please let me know. |
I'll take a look tomorrow. |
I don't how run commands on your CodeSandbox, but indeed, |
So for pug files, you need to run However, there is still an area that we can improve that there is no need format the inline scripts inside pug. |
What version of
eslint
are you using?8.55.0
What version of
prettier
are you using?3.1.0
What version of
eslint-plugin-prettier
are you using?5.0.1
Please paste any applicable config files that you're using (e.g.
.prettierrc
or.eslintrc
files).prettierrc
.eslintrc.json
What source code are you linting?
The plugin is working incorrectly in the files that use template pug (jade).
In the other files (like js) it is working correctly.
What did you expect to happen?
Report errors using the command
eslint file.pug
and highlight errors in the editor (VS Code).What actually happened?
The errors are not highlighted in the editor but when I save the file is automatically formatted correctly using prettier.
The command eslint doesn't return any errors:
But the command prettier report some errors:
Steps to reproduce
You can find an example at this link: https://codesandbox.io/p/devbox/quizzical-joana-zlpzn8
Javascript working as expected:
npm run prettier:js
-> errors are foundnpm run lint:js
-> errors from prettier are reportedPug not working:
npm run prettier:pug
-> errors are foundnpm run lint:js
-> no errors reportedThe text was updated successfully, but these errors were encountered: