Three of my Django apps have static files with the same name app1/static/css/mycss.css
, app2/static/css/mycss.css
, app3/static/css/mycss.css
. How do I collect them all to STATIC_ROOT since default behavior of DJango is to collect only the first one encountered among the same named static file?
If you don't want the static files to be getting in each others way, give them their own name space by creating a suitable folder structure. Example
app1/static/css/app1/mycss.css
app2/static/css/app2/mycss.css
Alternatively if you want to combine all the CSS into one big CSS look into django-compressor
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments