daidodo / format-imports-vscode

Format imports and exports for JavaScript and TypeScript in VS Code.
https://marketplace.visualstudio.com/items?itemName=dozerg.tsimportsorter
MIT License
62 stars 5 forks source link

Use eslint/prettier/editorconfig configuration for quotemark #102

Open tmcappsph opened 11 months ago

tmcappsph commented 11 months ago

Currently, the extension is not using the eslint/prettier/editorconfig configurations for the quotemark configuration. It would be great to include quotemark in the configuration resolution.

daidodo commented 9 months ago

@tmcappsph Thanks for the feedback!

Could you be specific about the quotemark config in eslint/prettier/editorconfig that you think it should consider?

tmcappsph commented 9 months ago

@daidodo

For eslint: quotes: ["error", "<single/double/backtick>"] https://eslint.org/docs/latest/rules/quotes (This rule was deprecated in ESLint v8.53.0 in favor for https://eslint.style/rules/js/quotes)

For eslint stylistic @stylistic/js/quotes: ["error", "<single/double/backtick>"] https://eslint.style/rules/js/quotes

For prettier: singleQuote: <true/false> https://prettier.io/docs/en/options.html#quotes

For editorconfig: quote_type = <single/double/auto> https://github.com/editorconfig/editorconfig/wiki/EditorConfig-Properties#ideas-for-domain-specific-properties

Appreciate you looking into this.

daidodo commented 9 months ago

The plugin supported Prettier and editorconfig already but was not working due to a bug. I fixed it and published a new version v7.6.8.

For eslint config for quote, it's not supported yet. I'll work on it later. Or welcome someone to help.

Thanks!

tmcappsph commented 9 months ago

Great. Thanks.