Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Asset managers for Django - choose which one? [closed]

Tags:

I would like to bundle up css and javascript files. I also want to send far-future expire headers to clients, so I need file versioning.

A quick search across the Internet has shown there are several asset managers developed for Django. Here is a list of those that I could reach:

  1. django-compress
  2. django-assets
  3. django-assetpackager
  4. django-media-bundler
  5. django-mediacat
  6. django-site-assets
  7. django-static-management
  8. django-compressor

They seem to perform more or less the same job. django-compress, django-compressor and django-site-assets seem to be especially promising at the first glance. I will appreciate if someone provides feedback on any of them that will help me choose between them.

like image 938
shanyu Avatar asked Nov 05 '09 22:11

shanyu


1 Answers

As you have already noticed, they all do the same thing (more or less). I decided to go ahead with django_compressor.

Also, I prefer to set expire headers or apply on-the-fly compression at the web server level. IMHO these operations should not be performed by the application itself, because sometimes it can lead to some issues, for instance setting Cache-Control or expiration headers on error pages etc. The mod_expires module is very easy to configure according to your needs. For on-the-fly compression using the DEFLATE output filter, I have used this mod_deflate configuration as is.

like image 104
Born To Ride Avatar answered Oct 12 '22 14:10

Born To Ride