Feedback

admin-crud-page

@svelte-society Claim

Basic information

Repository
svelte-society
Skill
admin-crud-page

About admin-crud-page

CLI tools for Svelte 5 documentation lookup and code analysis. MUST be used whenever creating or editing any Svelte component (.svelte) or Svelte module (.svelte.ts/.svelte.js). If possible, this skill should be executed within the svelte-file-editor agent for optimal results.

admin-crud-page is an agent skill listed in the AddMCP.net directory, published by svelte-society. Runtime: TypeScript. The repository has 450 GitHub stars. Source code is hosted on github.com. Related topics: javascript, svelte, sveltekit.

Overview

What is admin-crud-page?


name: Admin CRUD Page description: Create admin dashboard pages with tables, forms, and actions


Admin CRUD Page Pattern

Use this skill when creating admin pages for managing entities.

When to Use

  • Adding a new admin section (e.g., /admin/[feature])
  • Creating admin list pages with tables and row actions
  • Creating admin edit/create forms with headers

Note: For general page patterns (forms, filters, pagination, remote functions), see [page-builder](../page-builder/SKILL.md).

Route Structure

Admin routes live in src/routes/(admin)/admin/:

src/routes/(admin)/admin/
└── [feature]/
    ├── +page.svelte          # List page (pure renderer)
    ├── data.remote.ts        # Remote functions (all logic here)
    ├── [id]/
    │   └── +page.svelte      # Edit page
    └── new/
        └── +page.svelte      # Create page (optional)

IMPORTANT: Never use +page.server.ts This project uses Remote Functions exclusively for server-side logic. All data loading, form handling, and mutations must go through .remote.ts files. Never create +page.server.ts, +server.ts, or use SvelteKit form actions.

Admin-Specific Components

| Component | Purpose | Import | | ------------------- | ----------------------------------------------- | ---------------------------------------- | | PageHeader | Page title with icon and actions | $lib/ui/admin/PageHeader.svelte | | Table | Data table with snippets for header/row/actions | $lib/ui/admin/Table.svelte | | AdminList | Simple wrapper with title and "New" button | $lib/ui/admin/AdminList.svelte | | StatusSelect | Status filter dropdown | $lib/ui/admin/StatusSelect.svelte | | TypeSelect | Content type filter | $lib/ui/admin/TypeSelect.svelte | | Badge | Status/type badges | $lib/ui/admin/Badge.svelte | | Actions | Row action buttons (edit, delete, custom) | $lib/ui/admin/Actions | | ContentPicker | Select related content | $lib/ui/admin/ContentPicker.svelte | | QuickAction | Dashboard quick action cards | $lib/ui/admin/QuickAction.svelte | | ConfirmWithDialog | Confirmation dialog wrapper | $lib/ui/admin/ConfirmWithDialog.svelte |

Quick Start

### List Page ```svelte
{#snippet header(classes)} {/snippet} {#snippet row(item, classes)} {/snippet} {#snippet actionCell(item)} {/snippet}
Name Status{item.name} {item.status}
``` ### Edit Page ```svelte
Save
```

Authorization

Always call checkAdminAuth() first in admin remote functions:

import { checkAdminAuth } from '../authorization.remote'

export const getItems = query('unchecked', async (searchParams) => {
	checkAdminAuth() // Throws if not admin
	// ... rest of logic
})

Reference Files

  • [LIST-PAGE.md](./LIST-PAGE.md) - Table, Actions, Badge patterns
  • [EDIT-PAGE.md](./EDIT-PAGE.md) - PageHeader, ConfirmWithDialog patterns
  • [TEMPLATES.md](./TEMPLATES.md) - Copy-paste starter templates

General Patterns

For patterns that apply to both admin and public pages, see:

  • [page-builder/LIST-PAGE.md](../page-builder/LIST-PAGE.md) - Filters, search, pagination
  • [page-builder/DETAIL-PAGE.md](../page-builder/DETAIL-PAGE.md) - Forms, validation
  • [page-builder/FEED-PAGE.md](../page-builder/FEED-PAGE.md) - Mixed-type feeds
  • [using-remote-functions/REMOTE-FIRST.md](../using-remote-functions/REMOTE-FIRST.md) - Remote-first architecture

Comments

No comments yet

Be the first to share feedback about this listing. Sign in to leave a comment.

Sign In

Feedback 💬