Combine angular and django url

What is the standard way to determine URLs when using Django, AngularJS and Django-Rest-Framework?

In other words, is it more possible to define SPA URLs instead of defining it in both Angular and Django ?

+7
angularjs django django-urls django-rest-framework angularjs-routing
source share
1 answer

Django-Angular actually provides javascript handlers that work similar to the template tags {% url ... %} and the django reverse functions.

From django-angular readthedocs on managing URLs :

Starting with version 0.8, django-angular provides a new way to handle URLs, which offers the function of inverting directly to AngularJS modules.

This service is provided by the djangoUrl.reverse(name, args_or_kwargs) . It behaves exactly like a Djangos URL pattern template .

Django-Angular provides many helper functions for integrating Django and Angular, and you could probably check.

+3
source share

All Articles