Skip to content

Commit

Permalink
Fix false positives for non-vue file in `vue/multi-word-component-nam…
Browse files Browse the repository at this point in the history
…es` rule (#1684)
  • Loading branch information
ota-meshi committed Oct 29, 2021
1 parent 0437972 commit afec265
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions tests/lib/rules/multi-word-component-names.js
Expand Up @@ -169,6 +169,35 @@ tester.run('multi-word-component-names', rule, {
}
</script>
`
},
{
filename: 'test.js',
code: `
new Vue({})
`
},
{
// https://github.com/vuejs/eslint-plugin-vue/issues/1670
filename: 'main.ts',
code: `
import Vue from 'vue'
import VueCompositionAPI, { h } from '@vue/composition-api'
import i18n from '@/i18n'
import router from '@/router'
import store from '@/store'
// ...
Vue.use(VueCompositionAPI)
new Vue({
i18n,
router,
store,
setup() {
return () => h(App)
},
}).$mount('#app')
`
}
],
invalid: [
Expand Down

0 comments on commit afec265

Please sign in to comment.