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

Incorrect handling of attributes with a template value #20

Open
apoblock opened this issue Nov 30, 2020 · 0 comments
Open

Incorrect handling of attributes with a template value #20

apoblock opened this issue Nov 30, 2020 · 0 comments

Comments

@apoblock
Copy link

If the attribute has a template value and is followed by other attribute, the linter will get incorrect attribute value.
For example following:

<tag attr1={val} attr2="some-other-val" attr3="">...</tag>

when run with --attributes "attr1" --templateDelimiters "{,}", will get attr2="some-other-val" as a value of attr1.

The reason is that the tool internally replaces template code with a space before processing a file what yields something like this:

<tag attr1= attr2="some-other-val" attr3="">...</tag>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant