amatiasq / vsc-sort-imports

Sort ES6 imports automatically.
ISC License
58 stars 24 forks source link

.vue SFC support #17

Closed rndmerle closed 6 years ago

rndmerle commented 6 years ago

Hi.

import-sort is handling VueJS SFC quite well actually, as you can see here : https://github.com/renke/import-sort/issues/52

So I thought I'll give a try to the VSCode extension. With .importsortrc config:

{
    ".vue, .ts": {
      "parser": "typescript",
      "style": "module"
    }
}

I edited your package.json to add "onLanguage:vue" but the command still does nothing on a .vue file. No error showing in the console.

Any idea ? :) Thanks for your time.

Airkro commented 6 years ago

in settings.json

"sort-imports.languages": [
  "typescript",
  "javascript",
  "vue"
]
rndmerle commented 6 years ago

Thanks :) No clue why I didn't see it before.