esbuild-os-notifier
v1.1.3
Published
Esbuild OS Notification Plugin
Maintainers
Readme
esbuild-os-notifier
Native OS notifications for your esbuild builds — know the moment your build passes, fails, or emits warnings without leaving your editor.
Cross-platform support for macOS, Windows, and Linux via node-notifier.
Install
npm i -D esbuild-os-notifieryarn add -D esbuild-os-notifierpnpm add -D esbuild-os-notifierUsage
import { build } from 'esbuild'
import esbuildOsNotifier from 'esbuild-os-notifier'
await build({
entryPoints: ['src/index.js'],
bundle: true,
outfile: 'dist/index.js',
plugins: [esbuildOsNotifier()],
})Options
esbuildOsNotifier(
{
// node-notifier options
contentImage: './logo.png', // Path to a custom icon (300×300px recommended)
sound: true, // Play a sound with the notification
timeout: 5000, // Auto-dismiss after 5 seconds
},
{
// Toggle per-category notifications
warnings: true,
errors: true,
success: true,
}
)Defaults
By default all three notification types are enabled. Set any to false to suppress that category.
How it works
Hooks into esbuild's onStart and onEnd build events. When a build finishes:
- Success — a single notification with the build status
- Errors — individual notifications per error with file, line, and column info
- Warnings — individual notifications per warning with location info
