How to integrate Foundation 5 in django

放肆的年华 提交于 2019-11-29 20:02:03

问题


I'd like to starting use Foundation 5 in a django project. My doubts are about how to setup folders of Foundation project. Foundation now uses bower for js dipendencies. I think it's not correct make a foundation 5 set up into the static folder of django.

Has anyone done a setup of foundation in a django project?

To compile scss files I'll use django-compressor.


回答1:


My solution is use django-bower... that's all!




回答2:


Check here. It should have all the instructions. https://pypi.python.org/pypi/django-zurb-foundation




回答3:


I've been playing with foundation on my django project using the django development server. All I did was download the Foundation 5 static files (JS,CSS) and add them to my django static files. Then I added in the necessary scripts to my base template as shown here: http://foundation.zurb.com/docs/css.html. I haven't put it into production yet but I don't see any reason why that wouldn't work or why using static files isn't correct (as you thought in your question).

There are benefits to compiling the CSS yourself with SASS if you're really hardcore and I imagine that using template tags with django-zurb-foundation is a little cleaner or maybe easier to implement if you have tons of templates that you would need to modify but if you're like me and you just want to try Foundation out on a small project then downloading the extra applications (django-bower, django-zurb-foundation) isn't necessary.



来源:https://stackoverflow.com/questions/20324170/how-to-integrate-foundation-5-in-django

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!