-settings.py 설정
-STATIC_ROOT = os.path.join(BASE_DIR, "staticfiles")
모든 정적 파일을 한 곳에 모아넣는 경로이다
-Python manage.py collectstatic 하면 static 폴더 생성됨: 모든 static이 모임
-base.css에 디자인 설정 후 연동하기-->head.html의 <head>부분에 링크 설정하기
{% load static %}
<head>
~
<link rel="stylesheet" href={% static 'base.css' %}>
~
</head>
-{% load static %} 구문을 작성해야 static과 관련된 코드를 작성할 수 있음
-링크 작성하여 static내의 base.css와 연결
http 프로토콜 (15~16강) (0) | 2021.07.19 |
---|---|
models.py class 작성 (14강) (0) | 2021.07.15 |
부트스트랩 적용 (10강) (0) | 2021.07.15 |
include와 extends 이용 (pinterest clone 9강) (0) | 2021.07.14 |
templates내용 뜨게 하기(pinterest clone 8강) (0) | 2021.07.14 |
댓글 영역