Skip to content
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

Feature Request: Lint <script> content in HTML block #83

Closed
fengyuanchen opened this issue Aug 30, 2017 · 6 comments
Closed

Feature Request: Lint <script> content in HTML block #83

fengyuanchen opened this issue Aug 30, 2017 · 6 comments
Labels

Comments

@fengyuanchen
Copy link

fengyuanchen commented Aug 30, 2017

# Example

```html
<h1>Hello, World!</h1>

<script>
  const a = 42;
  a = 'oops'; // Error (no-const-assign): `a` is constant.
<script>

<style></style>
```
@vsemozhetbyt
Copy link

You can use eslint-plugin-html for now.

@fengyuanchen
Copy link
Author

@vsemozhetbyt Both eslint-plugin-html and eslint-plugin-markdown are used, but not work for script in HTML block.

@btmills
Copy link
Member

btmills commented Aug 30, 2017

@fengyuanchen do you want to lint <script> tags in .html files or in HTML markup <script> tags embedded in .md files?

@fengyuanchen
Copy link
Author

@btmills Lint <script> tag content in HTML code block of .md files.

@zimme
Copy link

zimme commented Dec 27, 2017

There is eslint-plugin-script-tags.

@btmills
Copy link
Member

btmills commented Apr 7, 2018

@zimme thanks for the find! Looks like eslint-plugin-script-tags handles this nicely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants