Add a data table: Free AI Prompt | SheCodes

Free AI prompt · The Code Book

Add a data table

A ready-to-use prompt from the chapter Dashboards & Admin. Paste it into Claude, ChatGPT, Lovable, Bolt or any AI coding tool.

The prompt

“Create a reusable data table component with: column sorting (click header to sort), search/filter bar, pagination (10/25/50 per page), row selection with checkboxes, and action buttons (Edit, Delete) on each row. Style with Tailwind CSS. Make it responsive: on mobile, show a card layout instead of a table.”

How to use it

  1. Copy the prompt and paste it into your AI coding tool.
  2. Check the result in the preview, then ask for changes one at a time: "make the buttons bigger", "use my brand colours".
  3. Read the chapter to understand why it works and what to do next.

More prompts like this

All prompts

Build a complete dashboard

“Build an admin dashboard with: a collapsible sidebar (Overview, Users, Products, Orders, Settings), a top header with search bar and user avatar dropdown, 4 stat cards (Total Users, Revenue, Orders, Conversion Rate with trend indicators), a line chart showing revenue over the last 30 days, and a recent orders table with status badges. Use Tailwind CSS and Recharts for the chart. Make the sidebar collapse to icons on mobile.”

Build a settings page

“Create a settings page with a tab navigation: Profile (edit name, email, bio, upload avatar), Notifications (toggle email notifications for different events), Billing (show current plan, usage, upgrade button), and Team (list members with roles, invite new member form). Use Tailwind CSS with form validation.”

Set up a frontend project

“Set up a new Next.js project with TypeScript, Tailwind CSS, and App Router. Create a clean homepage with a [header/hero/features] layout.”

Add multi-page navigation

“Convert my single-page app into multiple pages with proper navigation. Add routes for [home, about, dashboard, settings].”

Make it responsive

“Make my website fully responsive so it looks great on phones, tablets, and desktops. Use Tailwind CSS breakpoints and make sure the navigation works on mobile with a hamburger menu.”

Set up a backend with supabase

“Set up a backend for my app using Supabase. I need tables for [users, posts, comments]. Include row-level security policies so users can only edit their own data.”