Posts

Showing posts from October, 2025
Create a folder in the project root directory named " z_css " for tailwind Open terminal and go inside " z_css " type " npm init -y " and enter run npm install tailwindcss @tailwindcss/cli create file " input.css " inside z_css folder and paste the code @import "tailwindcss" source (none); @source "../templates/**/*.html" ; @source "../**/templates/**/*.html" ; Inside package.json paste the following code "dev" : "npx @tailwindcss/cli -i ./src/input.css -o ../static/css/tailwind.output.css --watch" , "build" : "npx @tailwindcss/cli -i ./src/input.css -o ../static/css/tailwind.output.css --minify" Now at last add below code to settings.py in django below STATIC_URL = 'static/' STATICFILES_DIRS = [             os . path . join ( BASE_DIR , 'static' ),         ] STATIC = '/static/' STATIC_ROOT = os . path . join ( BASE_DIR , 'staticfiles...