django-js-utils 0.0.5

Django app to help RIA development on top of a Django backend

  Add it to your Download Basket!

 Add it to your Watch List!

0/5

Rate it!
send us
an update
LICENSE TYPE:
BSD License 
USER RATING:
UNRATED
  0.0/5
DEVELOPED BY:
Vebjorn Ljosa
HOMEPAGE:
pypi.python.org
CATEGORY:
ROOT \ Internet \ HTTP (WWW)
django-js-utils is a Django app that aims to offer Django/JavaScript developers with various tools which will help RIA development on top of a Django backend.

Installation and usage

- Add django_js_utils to your python path and add the django_js_utils application to your INSTALLED_APPS
- Add the jsurls view to your URL patterns, e.g.,

(r'^jsurls.js$', 'django_js_utils.views.jsurls', {}, 'jsurls'),

- Load the static django_js_utils.js (which contains the reverse function) and the dynamically-generated jsurls.js from every web page where you plan to use the reverse function (likely just your base.html template). Example:

< script type="text/javascript" src="{% staticfile 'django_js_utils.js' %}" >< /script >
< script type="text/javascript" src="{% url jsurls %}" >< /script >


- In your JavaScript code, reverse URLs as follows:

django_js_utils.urls.resolve('dashboard')
django_js_utils.urls.resolve('time_edit', { project_id: 1, time_id: 2 })


For more information about usage, see example.html

Last updated on September 10th, 2012

requirements

#Django backend #RIA development #Django #backend #RIA #development

Add your review!

SUBMIT