一、解决不必要的django语法报错
安装配置pylint-django插件解决。
1.1 下载插件
在命令行执行:
pip install pylint-django
1.2 配置插件
在 VS Code
中,File >> Preferences >> Settings 中:
找到Python > Linting:Pylint Args
选项,
添加参数:
--load-plugins=pylint_django
# 如想设置error级别,可添加:
--errors-only
保存即可,如不生效可重启再行查看。
二、左侧文件目录缩进不明显
在File >> Preferences >> Settings 中:
搜索:TreeIndent
将其缩进像素加大即可: