django-angular


Namedjango-angular JSON
Version 2.3.1 PyPI version JSON
download
home_pagehttps://github.com/jrief/django-angular
SummaryLet Django play well with AngularJS
upload_time2023-11-13 22:42:41
maintainer
docs_urlNone
authorJacob Rief
requires_python
licenseMIT
keywords django angularjs
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage
            # django-angular

Let Django play well with AngularJS

[![Build Status](https://travis-ci.org/jrief/django-angular.svg?branch=master)](https://travis-ci.org/jrief/django-angular)
[![PyPI version](https://img.shields.io/pypi/v/django-angular.svg)](https://pypi.python.org/pypi/django-angular)
[![Python versions](https://img.shields.io/pypi/pyversions/django-angular.svg)](https://pypi.python.org/pypi/django-angular)
[![Software license](https://img.shields.io/pypi/l/django-angular.svg)](https://github.com/jrief/django-angular/blob/master/LICENSE-MIT)
[![Twitter Follow](https://img.shields.io/twitter/follow/jacobrief.svg?style=social&label=Jacob+Rief)](https://twitter.com/jacobrief)


## Deprecation Warning: [AngularJS is dead](https://blog.angular.io/discontinued-long-term-support-for-angularjs-cc066b82e65a) 

Since AngularJS is deprecated now, this library shall not be used for new projects anymore.
Instead please proceed with my follow-up project [django-formset](https://github.com/jrief/django-formset).
All the useful features for Django Form validation have been reimplemented in **django-formset**, this time
in vanilla TypeScript and without depending on any third party package.


## What does it offer?

Add AngularJS directives to Django Forms. This allows to handle client side form validation using
the constraints provided by the server side Form declaration.

For more information, please visit the [demo site](https://django-angular.awesto.com/form_validation/).


### How to run

```
git clone https://github.com/jrief/django-angular.git django-angular.git
cd django-angular.git
docker build -t django-angular.git .
docker run -d -it -p 9002:9002 django-angular.git
```

Open the application at `http://{docker-host's-ip}:9002/`

### Backward Incompatibility

To be compliant with other libraries such as **djangorestframework**,  server-side responses on
rejected forms use error code 422, rather than 200. If you use your own form controllers, adopt
them accordingly. The JSON format used to communicate errors downstream has changed slightly.

### New Features

For a smoother transition path, **django-angular** added two directives in version 2.0:

``<form djng-endpoint="/path/to/endpoint">...</form>``, which can be used to upload form
data to the server. It also populates the error fields, in case the server rejected some data.

``<djng-forms-set endpoint="/path/to/endpoint"><form ...>...</form>...</djng-forms-set>``
Similar to the above directive, but rather than validating one single form, it validates a
set of forms using one shared endpoint.

A promise chain has been introduced. Buttons used to submit form data and then proceed with
something else, now can be written as:

``<button ng-click="do(update()).then(redirectTo('/path/to/other/page'))">Label</button>``


## Documentation

Detailed documentation on [ReadTheDocs](http://django-angular.readthedocs.org/en/latest/).

[Demo](http://django-angular.awesto.com/form_validation/) on how to combine Django with Angular's form validation.

Please drop me a line, if and where you use this project.


## Features

* Seamless integration of Django forms with AngularJS controllers.
* Client side form validation for Django forms using AngularJS.
* Let an AngularJS controller call methods in a Django view - kind of Javascript RPCs.
* Manage Django URLs for static controller files.
* Three way data binding to connect AngularJS models with a server side message queue.
* Perform basic CRUD operations.

## Examples

* Implement Filter On Single Page Application using Django & Angular JS https://shriniket.home.blog/2019/09/22/integrate-angular-js-with-django-filter-application/


## License

Copyright &copy; 2019

MIT licensed

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/jrief/django-angular",
    "name": "django-angular",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "Django,AngularJS",
    "author": "Jacob Rief",
    "author_email": "jacob.rief@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/10/2f/150b761f96b0e64b6a77c313b958e9177bc6cebaa4f713b8875b169b6b96/django-angular-2.3.1.tar.gz",
    "platform": "OS Independent",
    "description": "# django-angular\n\nLet Django play well with AngularJS\n\n[![Build Status](https://travis-ci.org/jrief/django-angular.svg?branch=master)](https://travis-ci.org/jrief/django-angular)\n[![PyPI version](https://img.shields.io/pypi/v/django-angular.svg)](https://pypi.python.org/pypi/django-angular)\n[![Python versions](https://img.shields.io/pypi/pyversions/django-angular.svg)](https://pypi.python.org/pypi/django-angular)\n[![Software license](https://img.shields.io/pypi/l/django-angular.svg)](https://github.com/jrief/django-angular/blob/master/LICENSE-MIT)\n[![Twitter Follow](https://img.shields.io/twitter/follow/jacobrief.svg?style=social&label=Jacob+Rief)](https://twitter.com/jacobrief)\n\n\n## Deprecation Warning: [AngularJS is dead](https://blog.angular.io/discontinued-long-term-support-for-angularjs-cc066b82e65a) \n\nSince AngularJS is deprecated now, this library shall not be used for new projects anymore.\nInstead please proceed with my follow-up project [django-formset](https://github.com/jrief/django-formset).\nAll the useful features for Django Form validation have been reimplemented in **django-formset**, this time\nin vanilla TypeScript and without depending on any third party package.\n\n\n## What does it offer?\n\nAdd AngularJS directives to Django Forms. This allows to handle client side form validation using\nthe constraints provided by the server side Form declaration.\n\nFor more information, please visit the [demo site](https://django-angular.awesto.com/form_validation/).\n\n\n### How to run\n\n```\ngit clone https://github.com/jrief/django-angular.git django-angular.git\ncd django-angular.git\ndocker build -t django-angular.git .\ndocker run -d -it -p 9002:9002 django-angular.git\n```\n\nOpen the application at `http://{docker-host's-ip}:9002/`\n\n### Backward Incompatibility\n\nTo be compliant with other libraries such as **djangorestframework**,  server-side responses on\nrejected forms use error code 422, rather than 200. If you use your own form controllers, adopt\nthem accordingly. The JSON format used to communicate errors downstream has changed slightly.\n\n### New Features\n\nFor a smoother transition path, **django-angular** added two directives in version 2.0:\n\n``<form djng-endpoint=\"/path/to/endpoint\">...</form>``, which can be used to upload form\ndata to the server. It also populates the error fields, in case the server rejected some data.\n\n``<djng-forms-set endpoint=\"/path/to/endpoint\"><form ...>...</form>...</djng-forms-set>``\nSimilar to the above directive, but rather than validating one single form, it validates a\nset of forms using one shared endpoint.\n\nA promise chain has been introduced. Buttons used to submit form data and then proceed with\nsomething else, now can be written as:\n\n``<button ng-click=\"do(update()).then(redirectTo('/path/to/other/page'))\">Label</button>``\n\n\n## Documentation\n\nDetailed documentation on [ReadTheDocs](http://django-angular.readthedocs.org/en/latest/).\n\n[Demo](http://django-angular.awesto.com/form_validation/) on how to combine Django with Angular's form validation.\n\nPlease drop me a line, if and where you use this project.\n\n\n## Features\n\n* Seamless integration of Django forms with AngularJS controllers.\n* Client side form validation for Django forms using AngularJS.\n* Let an AngularJS controller call methods in a Django view - kind of Javascript RPCs.\n* Manage Django URLs for static controller files.\n* Three way data binding to connect AngularJS models with a server side message queue.\n* Perform basic CRUD operations.\n\n## Examples\n\n* Implement Filter On Single Page Application using Django & Angular JS https://shriniket.home.blog/2019/09/22/integrate-angular-js-with-django-filter-application/\n\n\n## License\n\nCopyright &copy; 2019\n\nMIT licensed\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Let Django play well with AngularJS",
    "version": "2.3.1",
    "project_urls": {
        "Homepage": "https://github.com/jrief/django-angular"
    },
    "split_keywords": [
        "django",
        "angularjs"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5c3d789136a2ab3ecc251f7d27a4a9193e6e9cd2d434e6ae9bba87527ec38ac9",
                "md5": "707b249bd5c1e086b57c372f7289f7e9",
                "sha256": "4841cb6e8e3323300e7ffff44d8a7c54bc474974e76d7b47145c0010de79913b"
            },
            "downloads": -1,
            "filename": "django_angular-2.3.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "707b249bd5c1e086b57c372f7289f7e9",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 192840,
            "upload_time": "2023-11-13T22:42:39",
            "upload_time_iso_8601": "2023-11-13T22:42:39.687997Z",
            "url": "https://files.pythonhosted.org/packages/5c/3d/789136a2ab3ecc251f7d27a4a9193e6e9cd2d434e6ae9bba87527ec38ac9/django_angular-2.3.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "102f150b761f96b0e64b6a77c313b958e9177bc6cebaa4f713b8875b169b6b96",
                "md5": "646d9b9d4614a3e6b5970ca6acd53226",
                "sha256": "b9c97de2b4658d30f6e3a4f9d5515a479914ac5976a3cb46a609faae0bd95852"
            },
            "downloads": -1,
            "filename": "django-angular-2.3.1.tar.gz",
            "has_sig": false,
            "md5_digest": "646d9b9d4614a3e6b5970ca6acd53226",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 164441,
            "upload_time": "2023-11-13T22:42:41",
            "upload_time_iso_8601": "2023-11-13T22:42:41.706731Z",
            "url": "https://files.pythonhosted.org/packages/10/2f/150b761f96b0e64b6a77c313b958e9177bc6cebaa4f713b8875b169b6b96/django-angular-2.3.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-11-13 22:42:41",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "jrief",
    "github_project": "django-angular",
    "travis_ci": true,
    "coveralls": true,
    "github_actions": true,
    "tox": true,
    "lcname": "django-angular"
}
        
Elapsed time: 0.13658s