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

multiline-html-element-content-newline case sensitivity #662

Closed
armano2 opened this issue Nov 13, 2018 · 1 comment
Closed

multiline-html-element-content-newline case sensitivity #662

armano2 opened this issue Nov 13, 2018 · 1 comment
Assignees
Labels

Comments

@armano2
Copy link
Contributor

armano2 commented Nov 13, 2018

Tell us about your environment

  • ESLint version: 5.9.0
  • eslint-plugin-vue version: 5.0.0.beta4 0fd0f7b
  • Node version: 10

Please show your full configuration:

{
  "vue/multiline-html-element-content-newline": ["error", {
    "ignores": ["VueComponent", "pre", "textarea"]
  }]
}

What did you do?

<VueComponent>multiline
content</VueComponent>

<VueComponent><span
  class="bold">For example,</span>
Defines the Vue component that accepts preformatted text.</VueComponent>

What did you expect to happen?
There should be no errors

What actually happened?

[ESLint] Expected 1 line break after opening tag (`<vuecomponent>`), but no line breaks found. (vue/multiline-html-element-content-newline)
...

https://armano2.github.io/eslint-plugin-vue/rules/multiline-html-element-content-newline.html#ignores-vuecomponent-pre-textarea

Test case

[
    {
      code: `
        <template>
          <IgnoreTag>content</IgnoreTag>
          <IgnoreTag
            id="test-pre"
          >content</IgnoreTag>
          <IgnoreTag><div
            >content</div></IgnoreTag>
          <IgnoreTag>>content
            content</IgnoreTag>
        </template>`,
      options: [{
        ignores: ['IgnoreTag']
      }]
    },
]
@armano2
Copy link
Contributor Author

armano2 commented Nov 13, 2018

we should also check for IgnoreTag -> ignore-tag matching

@armano2 armano2 assigned armano2 and unassigned ota-meshi Nov 14, 2018
armano2 added a commit to armano2/eslint-plugin-vue that referenced this issue Nov 14, 2018
armano2 added a commit to armano2/eslint-plugin-vue that referenced this issue Nov 14, 2018
armano2 added a commit to armano2/eslint-plugin-vue that referenced this issue Nov 14, 2018
michalsnik pushed a commit that referenced this issue Nov 18, 2018
* Fix: multiline-html-element-content-newline case sensitivity

fix issue #662

* fix typo in tests
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

3 participants