Search code examples
djangodjango-crispy-formsgetuikit

Use django-crispy-forms with Uikit


I'm building a website with django and i'm using uikit 3 as front-end framework is there any way to style django-crispy-forms with uikit ? with bootstrap i can just put this line on settings file :

CRISPY_TEMPLATE_PACK = 'bootstrap4'

is their any option like this to use uikit ?


Solution

  • You should always check the documentation of the packages you use:

    https://django-crispy-forms.readthedocs.io/en/latest/install.html#template-packs

    Since version 1.1.0, django-crispy-forms has built-in support for different CSS frameworks, known as template packs within django-crispy-forms:

    • bootstrap Bootstrap is crispy-forms’s default template pack, version 2 of the popular simple and flexible HTML, CSS, and Javascript for user interfaces from Twitter.
    • bootstrap3 Twitter Bootstrap version 3.
    • bootstrap4 Alpha support for Twitter Bootstrap version 4, which is still in Alpha.
    • uni-form Uni-form is a nice looking, well structured, highly customizable, accessible and usable forms.
    • foundation Foundation In the creator’s words, “The most advanced responsive front-end framework in the world.” This template pack is externally available through crispy-forms-foundation