You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the moment mootools-depender implements several separate functions:
Combine js files into one according to dependency information;
infrastructure to serve the result file;
public interface to generate mootools builds
I think these functions are totally separate and it will be better if mootools-depender will be split into several packages.
Combining files into 1 don't have to be related to django at all. It also don't have to be tied to exact serving infrastructure and the public interface. I think it is a wrong direction to move all the functionality into django management commands and it will be better to create a separate python package from 'core.py' and upload it to pypi. This way it can be used with other python frameworks, for automated build systems, programmatically with other js-combining packages like django-compress and django-compressor, etc.
As for file serving: serving files via django itself it is a very niche implementation. Nginx is much better at serving files and there are mature django apps that makes generation of combined js files easy and robust (django-compress, django-compressor). They handle cache issues (auto-versioning), compression (via YUI or any other compression tool), debugging (e.g. don't combine or compress files when DEBUG=True), but they don't handle dependency resolution. I think most django developers would prefer one of these implementation because they already use them and they are proven, stable and used in high-load. Using something that requires django to serve files feels scary and suitable only for development or for small sites.
So my proposal it to split core.py into separate python package (e.g. js-depender) that can be installed via pip install and then used stand-alone, with any python framework and with any compressing/combining utility (like mootools-depender, django-compress or django-compressor).
What do you think?
The text was updated successfully, but these errors were encountered:
At the moment mootools-depender implements several separate functions:
I think these functions are totally separate and it will be better if mootools-depender will be split into several packages.
Combining files into 1 don't have to be related to django at all. It also don't have to be tied to exact serving infrastructure and the public interface. I think it is a wrong direction to move all the functionality into django management commands and it will be better to create a separate python package from 'core.py' and upload it to pypi. This way it can be used with other python frameworks, for automated build systems, programmatically with other js-combining packages like django-compress and django-compressor, etc.
As for file serving: serving files via django itself it is a very niche implementation. Nginx is much better at serving files and there are mature django apps that makes generation of combined js files easy and robust (django-compress, django-compressor). They handle cache issues (auto-versioning), compression (via YUI or any other compression tool), debugging (e.g. don't combine or compress files when DEBUG=True), but they don't handle dependency resolution. I think most django developers would prefer one of these implementation because they already use them and they are proven, stable and used in high-load. Using something that requires django to serve files feels scary and suitable only for development or for small sites.
So my proposal it to split core.py into separate python package (e.g. js-depender) that can be installed via pip install and then used stand-alone, with any python framework and with any compressing/combining utility (like mootools-depender, django-compress or django-compressor).
What do you think?
The text was updated successfully, but these errors were encountered: