0

I have this code in VSCode:

import django
from models import Product

The problem is that when I save the file, VSCode change the code (somehow trying to beautify it):

from models import Product
import django

I had this Prettier extension, and I disabled it, but I still got the problem.

Mehrdad Salimi
  • 1,400
  • 4
  • 16
  • 31

1 Answers1

0

I turned off all the related extensions, but it didn't work.

SOLUTION:

In the end, what worked for me was to turn the Format On Save off. In VSCode: File -> Preferences -> Settings -> Text Editor -> Formatting.

Here turn the Format On Save off.

Mehrdad Salimi
  • 1,400
  • 4
  • 16
  • 31