Skip to content

Add guidance on how to lint JavaScript inside HTML files #199

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
dandv opened this issue Jul 20, 2024 · 1 comment · Fixed by #206
Closed

Add guidance on how to lint JavaScript inside HTML files #199

dandv opened this issue Jul 20, 2024 · 1 comment · Fixed by #206
Labels
documentation Improvements or additions to documentation

Comments

@dandv
Copy link

dandv commented Jul 20, 2024

From a quick look at this project, it appears it only lints HTML, and doesn't pass through the JavaScript in <script> tags to ESLint.

Whether that is correct or not, I think it would help to add a note to the README and to the homepage about how to lint JavaScript in HTML files.

@yeonjuan yeonjuan added the documentation Improvements or additions to documentation label Jul 23, 2024
@yeonjuan
Copy link
Owner

yeonjuan commented Jul 23, 2024

@dandv Thanks for reporting this issue.

From a quick look at this project, it appears it only lints HTML, and doesn't pass through the JavaScript in <script> tags to ESLint.

Yes, this plugin cannot lint javascript in a script. It would be nice to mention in the documentation to use eslint-plugin-html for linting js inside scripts.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants