ggascoigne / prettier-plugin-import-sort

Prettier plugin to pass javascript and typescript through import-sort
MIT License
110 stars 11 forks source link

Update for prettier v3.0.0 #28

Closed AdaskoTheBeAsT closed 10 months ago

AdaskoTheBeAsT commented 1 year ago

Hi,

thanks for cool plugin,

do you plan to upgrade it to be compatible with prettier v3.0.0?

barona-mika-vilpas commented 10 months ago

Is there something that is not working for you? I am using this in a project with the following versions and it seems to work:

Settings from package.json:

  "importSort": {
    ".js, .jsx, .ts, .tsx": {
      "style": "module",
      "parser": "typescript"
    }
  }

.prettierrc

{
  "printWidth": 120,
  "semi": false,
  "singleQuote": true,
  "trailingComma": "es5",
  "endOfLine": "lf",
  "proseWrap": "always",
  "plugins": ["prettier-plugin-import-sort"]
}
AdaskoTheBeAsT commented 10 months ago

:) I will need to recheck

AdaskoTheBeAsT commented 10 months ago

it is working again :) something was initially not working in prettier 3.0.x cool

u8675309 commented 10 months ago

With prettier 3, Plugin search feature has been removed.

If your prettier config previously said "plugins": [], it would work before prettier 3, but now you have to list every plugin like "plugins": ["prettier-plugin-import-sort"].

AdaskoTheBeAsT commented 10 months ago

closing - everything works :)