Live data from Hacker News

How to serve Django Statics (and not go insane)

blog.sendhub.com

31–34 of 34 posts

Re: How to serve Django Statics (and not go insane)

#32

You know, I've always found django-compressor to be adequate for my django statics needs. Was there a real need to reinvent the wheel in this case? Were you simply unable to configure django-compressor (or any other pre-existing django statics library) properly?

A little off topic, but a fault with django-compressor is that if you ever want to use jinja2, it only supports generating the compressed versions on the fly rather than via manage.py - I made a nasty hack that lets us do that but it wasn't easy. An even worse problem is that you won't be able to transition to using async dependency loading for your JavaScript since there's no way to get the filenames of each compres…

Check out django-require

Re: How to serve Django Statics (and not go insane)

#34
post #2

Nice post, tons of great advice. However, I have to say that the title is wrong. There's nothing django specific about any of those approaches. I've tried django-compress and it was a nightmare, the old style synccompress was actually easier to setup and get working for some reason.. Was hoping for a better rolled solution. Also, the part about cloudfront isn't written very clearly. I had to stop for a moment and thi…

Also, I can't tell you how much I hate that "cloudflare" sounds so much like "cloudfront". I've been in at least 6 convos where people were mixing one for the other. Esp, since they solve some of the same problems.

Just don't get either confused with "stormfront".
Post reply on HN