File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -133,9 +133,11 @@ The configuration above will look for javascript files in the folder `your_app/j
133133
134134If you add that folder to ` STATICFILES_DIRS ` in settings it will pick that compiled javascript and you can use it in templates.
135135
136- ``` text
136+ ``` python
137+ from pathlib import Path
138+ BASE_DIR = Path.cwd()
137139STATICFILES_DIRS = [
138- ("js", " /dist/js"),
140+ (" js" , f " { BASE_DIR } /dist/js " ),
139141]
140142```
141143
Original file line number Diff line number Diff line change 33"""
44
55import os
6+ from pathlib import Path
67
78# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
8- BASE_DIR = os . path . dirname ( os . path . dirname ( os . path . abspath ( __file__ )) )
9+ BASE_DIR = Path . cwd ( )
910# SECURITY WARNING: keep the secret key used in production secret!
1011SECRET_KEY = "a_not_so_secret_key"
1112
You can’t perform that action at this time.
0 commit comments