pythondjangotwitter-bootstrappycharm

Pycharm doesn't recognize .min.css file (Unresolved template reference) (Django)


I'm using Django with Pycharm.

I started to use Pycharm Professional today, and Pycharm doesn't recognize my bootstrap.min.css file.

<link rel="stylesheet" href="{% static 'bootstrap/css/bootstrap.min.css' %}">
Errors

I actually have that file in my project folder, but It doesn't appear in Pycharm file tree.
my project folder
pycharm file tree

Of course, I've set the static_dir, staticfiles_dirs, and static_root.
django static settings

This never happened in Pycharm educational version.

thank you


Solution

  • I solved the problem. You need to change the Pycharm preference.

    Preferences > Languages & Frameworks > Python Template Languages > Template language: Django

    pic