Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsCommunityBlog
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

Back to skills

Sonner

ASecurity

Opinionated toast notification component for React by Emil Kowalski — API, variants, patterns, clean code standards

3 stars
0 votes
0 copies
0 views
Added 9/19/2026
designgobashreactnodeapi

Works with

cliapi

Security Analysis

A92/100
mediumInstalls packages at runtime which could introduce malicious dependencies
mediumInstalls packages at runtime which could introduce malicious dependencies

Scanned 9/19/2026

Install to Claude Code

$npx -y skills add Ignvvcio254/Jarvis-254-Agent --skill sonner --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Sonner?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Sonner
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/ignvvcio254-sonner/badge)](https://www.skillsdirectory.com/skills/ignvvcio254-sonner)

More formats (shields.io, HTML) on the badges page.

Download with Pro
Files
SKILL.md
---
name: Sonner
description: Opinionated toast notification component for React by Emil Kowalski — API, variants, patterns, clean code standards
---

Sonner is an opinionated toast component for React by Emil Kowalski. Use it for all notification/feedback UI. It is the gold standard for toast UX.

## Installation

```bash
npm install sonner
# or
pnpm i sonner
```

## Setup

Place `<Toaster />` once at the root layout (works in server components like `layout.tsx`):

```tsx
import { Toaster } from 'sonner';

export default function RootLayout({ children }) {
  return (
    <html>
      <body>
        {children}
        <Toaster />
      </body>
    </html>
  );
}
```

## Toast Types

```tsx
import { toast } from 'sonner';

// Basic
toast('Message');

// Variants
toast.success('Saved successfully');
toast.error('Something went wrong');
toast.loading('Saving...');
toast.warning('Low disk space');
toast.info('Update available');

// With description
toast.success('File uploaded', {
  description: 'profile-photo.jpg has been uploaded.',
});

// Action button
toast('Message', {
  action: {
    label: 'Undo',
    onClick: () => console.log('Undo'),
  },
});

// Cancel button
toast('Message', {
  cancel: {
    label: 'Cancel',
    onClick: () => console.log('Cancelled'),
  },
});

// Promise (auto handles loading → success/error)
toast.promise(saveData(), {
  loading: 'Saving...',
  success: (data) => `Saved ${data.name}`,
  error: 'Failed to save',
});

// Custom JSX (fully custom, uses Sonner styles)
toast(<div>Custom <b>content</b></div>);

// Headless (no Sonner styles)
toast.custom((id) => (
  <div>
    Custom toast
    <button onClick={() => toast.dismiss(id)}>Close</button>
  </div>
));
```

## All Options

| Option | Type | Default | Description |
|--------|------|---------|-------------|
| `description` | ReactNode | — | Subtitle text |
| `duration` | number | 4000 | Auto-close ms (Infinity = never) |
| `position` | string | `bottom-right` | See positions below |
| `closeButton` | boolean | false | Show X button |
| `dismissible` | boolean | true | Swipe/click to dismiss |
| `icon` | ReactNode | — | Custom icon |
| `action` | object | — | `{ label, onClick }` |
| `cancel` | object | — | `{ label, onClick }` |
| `id` | string\|number | auto | For update/dismiss |
| `onDismiss` | function | — | Called when dismissed |
| `onAutoClose` | function | — | Called on auto-close |
| `style` | object | — | Inline styles |
| `className` | string | — | CSS class |

## Positions

`top-left` `top-center` `top-right` `bottom-left` `bottom-center` `bottom-right`

## Toaster Props

```tsx
<Toaster
  position="top-right"
  expand={false}          // expand all toasts (default: stack)
  richColors={true}       // vibrant success/error colors
  closeButton={true}      // global close button
  theme="light"           // 'light' | 'dark' | 'system'
  visibleToasts={3}       // max visible at once
  toastOptions={{         // default options for all toasts
    duration: 5000,
    classNames: {
      toast: 'my-toast',
      title: 'my-title',
    },
  }}
/>
```

## Update a Toast

```tsx
const id = toast.loading('Loading...');
// later:
toast.success('Done!', { id });
```

## Dismiss Programmatically

```tsx
toast.dismiss(id);    // dismiss specific
toast.dismiss();      // dismiss all
```

## Clean Code Rules

- Always use `toast.promise()` for async operations — never manually sequence loading/success/error toasts
- Set `duration: Infinity` for errors that require user action
- Use `richColors` in production for clear visual feedback
- Never show more than 3 toasts at once — set `visibleToasts={3}`
- Toasts are transitions (interruptible), not keyframe animations — this is intentional and correct

Attribution

Ignvvcio254Ignvvcio254
View sourceMore from Ignvvcio254 →
SSkills DirectorySkills Directory

Your tool, in front of Claude Code builders.

3 founder slots · $299/mo · GSC-verified traffic · sponsors can never buy grades.

See placements

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Your tool, in front of Claude Code builders.

3 founder slots · $299/mo · GSC-verified traffic · sponsors can never buy grades.

See placements

Related Skills

Responsive Design

Implement modern responsive layouts using container queries, fluid typography, CSS Grid, and mobile-first breakpoint strategies. Use when building adaptive interfaces, implementing fluid layouts, or creating component-level responsive behavior.

397922 votes

Mermaid Diagrams

Creating and refining Mermaid diagrams with live reload. Use when users want flowcharts, sequence diagrams, class diagrams, ER diagrams, state diagrams, or any other Mermaid visualization. Provides best practices for syntax, styling, and the iterative workflow using mermaid_preview and mermaid_save tools.

2062 votes

sleek-design-mobile-apps

Use when the user wants to design a mobile app, create screens, build UI, or interact with their Sleek projects. Covers high-level requests ("design an app that does X") and specific ones ("list my projects", "create a new project", "screenshot that screen").

5711 votes

swiftui-design-skill

SwiftUI frontend visual design skill. Creates beautiful, distinctive iOS/macOS interfaces that avoid generic AI slop patterns. Covers design direction, layout systems, typography, color, spacing, brand integration, and design review. Use when designing new SwiftUI views, reviewing UI quality, creating iOS prototypes, choosing visual styles, improving app aesthetics, or when the UI looks generic or AI-generated.

1801 votes

Ios Hig

Use when designing iOS interfaces, implementing accessibility (VoiceOver, Dynamic Type), handling dark mode, ensuring adequate touch targets, providing animation/haptic feedback, or requesting user permissions. Apple Human Interface Guidelines for iOS compliance.

761 votes
View all in design →