Skip to content

docs: Add guide for integrating Django Tailwind into existing projects#247

Merged
timonweb merged 3 commits intomasterfrom
copilot/add-django-tailwind-to-apps
Feb 19, 2026
Merged

docs: Add guide for integrating Django Tailwind into existing projects#247
timonweb merged 3 commits intomasterfrom
copilot/add-django-tailwind-to-apps

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 19, 2026

Users had no guidance on adding Django Tailwind to a project with pre-existing apps, scanning templates across multiple apps, or centralizing styles in a single theme app.

New page: docs/existing-project.md

  • Single theme app covers everything — clarifies that one theme app is the global entry point; no changes needed to existing apps
  • Source scanning — explains that the default @source "../../../**/*.{html,py,js}" already covers all apps in a standard layout
  • Non-standard layouts — shows how to stack multiple @source directives when apps live under a subdirectory (e.g. apps/)
  • Centralized styles — demonstrates using theme/static_src/src/styles.css as the single CSS entry point for custom variables and shared component classes
  • Existing base template — shows how to drop {% tailwind_css %} into an existing base.html without touching the theme app's own template

Updated docs/index.md

Added link to the new page in the table of contents (between Installation and Standalone vs npm-based).

Tailwind CSS v3 is deprecated; all examples use v4 @source directives only.

Original prompt

This section details on the original issue you should resolve

<issue_title>Doc request: Adding django-tailwind to existing apps</issue_title>
<issue_description>From the documentation it's unclear how to add django-tailwind to a app that already exists and how to work with multiple apps.

I'd also appreciate some guidance on how to proceed if I want to keep a central entry point for tailwind. In some projects I prefer a global static_src - how would I set that up?</issue_description>

<agent_instructions>Try to tackle this issue. I wonder how smart you are, Copilot.
</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: timonweb <483900+timonweb@users.noreply.github.com>
Copilot AI changed the title [WIP] Add django-tailwind setup instructions for existing apps docs: Add guide for integrating Django Tailwind into existing projects Feb 19, 2026
Copilot AI requested a review from timonweb February 19, 2026 11:48
Co-authored-by: timonweb <483900+timonweb@users.noreply.github.com>
@timonweb timonweb marked this pull request as ready for review February 19, 2026 12:07
@timonweb timonweb merged commit 9ea5a8a into master Feb 19, 2026
12 checks passed
@timonweb timonweb deleted the copilot/add-django-tailwind-to-apps branch February 19, 2026 12:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Doc request: Adding django-tailwind to existing apps

2 participants