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].

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

Development

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

  • Allow fields to be grouped into field sets

  • Is HTML creation mechanic good?

  • Support conditionally-revealed input boxes [2]

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.3.tar.gz (12.5 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.3-py3-none-any.whl (18.3 kB view details)

Uploaded Python 3

File details

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

File metadata

File hashes

Hashes for django-govuk-forms-0.3.tar.gz
Algorithm Hash digest
SHA256 76dadbb6f7c44ff3b1e3a13164cee0ae500f96051f391da8e5b3b2634a34bf37
MD5 7c9c77ceba31c0bcbdefaf9f1b2adaa8
BLAKE2b-256 307fb3188a7e36dc2c8e22ff3d56364c25556d2fb0fd02dd6bb3bb2f5917d055

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for django_govuk_forms-0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 2db25915e5e6669706192151111666f7ebcd15515c866ca11bf604df86568a37
MD5 a4c38c13e4dce34d624ac425ebf90b8e
BLAKE2b-256 0dde0d0a6ba13585251afd25b8c26ad0ec359908b42275f61b325de50c4f6370

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