Django, htmx, and Tailwind CSS
Setup
- Create and activate a virtual environment:
$ python3 -m venv venv && source venv/bin/activate
- Install the Python dependencies:
(venv)$ pip install -r requirements.txt
- Install the Node dependencies:
$ npm install tailwindcss postcss postcss-cli autoprefixer @fullhuman/postcss-purgecss
# you may need to install PostCSS globally as well
# npm install --global postcss postcss-cli
4 . Apply the migrations and run the Django development server:
(venv)$ python manage.py migrate
(venv)$ python manage.py runserver
- Test at http://localhost:8000/