目录
安装依赖,可参考另一篇文章:Backend - 安装依赖(pip 、tar.gz)_python通过tar.gz包安装依赖包-CSDN博客
# settings.py
INSTALLED_APPS = [
???? ?…
????'sass_processor',
]
STATICFILES_FINDERS = [
????'django.contrib.staticfiles.finders.FileSystemFinder',
????'django.contrib.staticfiles.finders.AppDirectoriesFinder',
????'sass_processor.finders.CssFinder',
]
SASS_PROCESSOR_ROOT = os.path.join(BASE_DIR, "luoboPro/static/")
# 或者 SASS_PROCESSOR_ROOT = os.path.join(BASE_DIR,'static','css')
{% load sass_tags %}
<link rel="stylesheet nofollow" type="text/css" ?href="{% sass_src 'scss/xxx/xxx.scss' %}">