Я попытался добавить проект sub frontend в свои шаблоны, но получил ошибку "Проверка MIME включена."?

  • goal I have two frontend project and I want to do create a new folder called build_2 inside my templates folder. inside the build_2 have index. html file and it was working just fine

  • problem but where I added <link href="my_styles. css" rel="stylesheet"> I got this error

  • Note: the directory myProject/home/templates/static/css/my_styles.css

полное сообщение об ошибке:

Refused to apply style from 'http://127.0.0.1:8000/css/my_styles.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
  • I tried
  1. add
#settings.py
TEMPLATES['DIRS'].append(os.path.join(BASE_DIR, 'home/templates/build2'), os.path.join(BASE_DIR, 'home/templates'))
  1. add
#settings.py
STATICFILES_DIRS.append(os.path.join(BASE_DIR, 'home/templates/static'))

но я все еще получаю ту же ошибку?

Вернуться на верх