Skip to main content

It should be easy to make a Django-based service that follows Government Digital Services’ style guide and reference materials.

This Django app allows forms to be output using the HTML that can be styled using GOV.UK elements. The styles themselves are provided by another package [1].

NB: Until version 1.0, there is likely going to be a lot of variation in the api, so it’s a good idea to pin a specific minor version.

Usage

  • Install django-govuk-forms or django-govuk-template[forms]

  • Add govuk_forms to INSTALLED_APPS

  • Inherit forms from govuk_forms.forms.GOVUKForm and use widgets from govuk_forms.widgets

See the demo folder in this repository on GitHub, it is not included in distributions.

Development

https://travis-ci.org/ministryofjustice/django-govuk-forms.svg?branch=master

Please report bugs and open pull requests on GitHub.

Use python setup.py test to run all tests.

This repository does not need to be updated for every release of GDS’s packages, only breaking changes for overridden components may need fixes.

If any localisable strings change, run python setup.py makemessages compilemessages.

Distribute a new version to PyPi by updating the VERSION tuple in govuk_forms and run python setup.py compilemessages sdist bdist_wheel upload.

To do

  • Is HTML creation mechanic good?

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-govuk-forms-0.6.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_govuk_forms-0.6-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

Details for the file django-govuk-forms-0.6.tar.gz.

File metadata

File hashes

Hashes for django-govuk-forms-0.6.tar.gz
Algorithm Hash digest
SHA256 86dbe1e6c40c5eb4243dc7b356eb35458ca226ce6ebcf140c02d9dd5f80326e3
MD5 74796e376b4c471a3ff098bdf9239931
BLAKE2b-256 ba325307f1178f30816838c7f82b3f54f20a23fb23f77e4bc27cfbcd950222c1

See more details on using hashes here.

File details

Details for the file django_govuk_forms-0.6-py3-none-any.whl.

File metadata

File hashes

Hashes for django_govuk_forms-0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 1c238e14fbc0c2ed298aa795921c6280285055379f4e5dfb5ab1512ba8cfa7ec
MD5 c7cc459e75fc5d6e31ac3fbb3a0ab195
BLAKE2b-256 bc21754585081e8d8d1709a19ce718bbd889e54c0c2af75f5863f943d99043cd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page