npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

gooey-toast-vue

v0.3.1

Published

A gooey, morphing toast notification library for Vue, powered by motion-v and vue-sonner

Downloads

114

Readme

gooey-toast-vue

A gooey, morphing toast notification library for Vue 3, powered by motion-v and vue-sonner.

Inspired by goey-toast for React.

Features

  • SVG blob morph animation from compact pill to expanded organic shape
  • Spring physics with configurable bounce and stiffness
  • 5 toast types: default, success, error, warning, info
  • Promise toasts with loading → success/error transitions
  • Action buttons with success label morphing
  • 4 animation presets: smooth, bouncy, subtle, snappy
  • Progress bar, close button, timestamp
  • Dark mode support
  • Swipe to dismiss
  • Nuxt 3 module included
  • Fully typed with TypeScript

Installation

npm install gooey-toast-vue

Quick Start

<script setup>
import { GooeyToaster, gooeyToast } from 'gooey-toast-vue'
import 'gooey-toast-vue/style.css'
</script>

<template>
  <div>
    <button @click="gooeyToast.success('Changes saved')">
      Show Toast
    </button>
    <GooeyToaster position="bottom-right" />
  </div>
</template>

Toast Types

import { gooeyToast } from 'gooey-toast-vue'

gooeyToast('Default notification')
gooeyToast.success('Changes saved')
gooeyToast.error('Something went wrong')
gooeyToast.warning('Please review your input')
gooeyToast.info('New update available')

With Description

gooeyToast.success('File uploaded', {
  description: 'Your file has been uploaded successfully.',
})

Action Button

gooeyToast.error('Failed to save', {
  description: 'Your changes could not be saved.',
  action: {
    label: 'Retry',
    onClick: () => retryOperation(),
    successLabel: 'Done!',
  },
})

Promise Toasts

gooeyToast.promise(fetchData(), {
  loading: 'Loading data...',
  success: (data) => `Loaded ${data.count} items`,
  error: 'Failed to load data',
  description: {
    loading: 'Please wait...',
    success: 'All items are now available.',
    error: 'Check your connection and try again.',
  },
})

Update Toast

const id = gooeyToast('Uploading...', { duration: Infinity })

// Later...
gooeyToast.update(id, {
  title: 'Upload complete',
  type: 'success',
  description: 'File is ready.',
})

Dismiss

// Dismiss specific toast
gooeyToast.dismiss(id)

// Dismiss all
gooeyToast.dismiss()

Composable

<script setup>
import { useGooeyToast } from 'gooey-toast-vue'

const { toast, dismiss, update } = useGooeyToast()

toast.success('Hello!')
</script>

Toaster Props

| Prop | Type | Default | Description | |------|------|---------|-------------| | position | GooeyToastPosition | 'bottom-right' | Toast position on screen | | theme | 'light' \| 'dark' | 'light' | Color theme | | preset | AnimationPresetName | — | Animation preset (smooth, bouncy, subtle, snappy) | | spring | boolean | true | Enable spring physics | | bounce | number | 0.4 | Spring bounce (0-0.8) | | duration | number | — | Default toast duration (ms) | | gap | number | 14 | Gap between stacked toasts (px) | | offset | string | '24px' | Distance from screen edge | | visibleToasts | number | 3 | Max visible toasts | | showProgress | boolean | false | Show progress countdown bar | | closeButton | boolean \| 'top-left' \| 'top-right' | false | Show close button | | closeOnEscape | boolean | true | Dismiss on Escape key | | dir | 'ltr' \| 'rtl' | 'ltr' | Text direction |

Toast Options

| Option | Type | Description | |--------|------|-------------| | description | string \| VNode \| Component | Toast description/body | | action | GooeyToastAction | Action button config | | icon | string \| VNode \| Component | Custom icon | | duration | number | Display duration (ms) | | id | string | Custom toast ID | | fillColor | string | SVG blob fill color | | borderColor | string | SVG blob border color | | borderWidth | number | SVG blob border width | | preset | AnimationPresetName | Per-toast animation preset | | spring | boolean | Per-toast spring toggle | | bounce | number | Per-toast spring bounce | | showProgress | boolean | Show progress bar | | showTimestamp | boolean | Show timestamp | | timing | GooeyToastTimings | Fine-grained timing control | | classNames | GooeyToastClassNames | CSS class overrides |

Animation Presets

gooeyToast.success('Saved', { preset: 'smooth' })
gooeyToast.success('Saved', { preset: 'bouncy' })
gooeyToast.success('Saved', { preset: 'subtle' })
gooeyToast.success('Saved', { preset: 'snappy' })

Or configure globally:

<GooeyToaster preset="bouncy" />

Custom Spring

gooeyToast.success('Saved', {
  spring: true,
  bounce: 0.6, // 0 (no bounce) to 0.8 (very bouncy)
})

Custom Styling

gooeyToast.info('Custom styled', {
  fillColor: '#f0f9ff',
  borderColor: '#0ea5e9',
  borderWidth: 2,
})

Override internal classes:

gooeyToast('Hello', {
  classNames: {
    title: 'my-title',
    description: 'my-desc',
    actionButton: 'my-btn',
  },
})

Vue Plugin

import { createApp } from 'vue'
import { GooeyToastPlugin } from 'gooey-toast-vue'
import 'gooey-toast-vue/style.css'

const app = createApp(App)
app.use(GooeyToastPlugin, {
  position: 'top-right',
  theme: 'dark',
  preset: 'bouncy',
})

Nuxt Integration

1. Install

npm install gooey-toast-vue

2. Add module to nuxt.config.ts

export default defineNuxtConfig({
  modules: ['gooey-toast-vue/nuxt'],
})

3. Add <GooeyToaster> to your layout

<!-- layouts/default.vue -->
<template>
  <div>
    <slot />
    <GooeyToaster position="bottom-right" />
  </div>
</template>

4. Use anywhere

<script setup>
// gooeyToast is auto-imported by the Nuxt module
gooeyToast.success('It works!')
</script>

The Nuxt module automatically:

  • Imports the CSS stylesheet
  • Registers GooeyToaster as a global component
  • Auto-imports gooeyToast and useGooeyToast
  • Marks the plugin as client-only (SSR safe)

License

MIT