Vladimir Despotovic
Vladimir Despotovic

Reputation: 3498

In VSCode, how to apply single quotes on python files, not only to typescript, with prettier?

Why is single quotes applied to typescript, but not to python files? I have prettier installed, but when I save a file, the .ts files are automatically formatted and single quotes is applied, but .py files are not. I have in settings.json file this setting:

"prettier.singleQuote": true,

and I see it is applied to angular files, but not to python files.

Upvotes: 1

Views: 1626

Answers (1)

Steven-MSFT
Steven-MSFT

Reputation: 8411

Because the Prettier extension only supports these languages:

JavaScript · TypeScript · Flow · JSX · JSON
CSS · SCSS · Less
HTML · Vue · Angular
GraphQL · Markdown · YAML

Does not include python.

And you can find, if you select Format Document With... in the python file, it will not list the Prettier.

Upvotes: 2

Related Questions