@retrigger/core weekly downloads statistics
By retrigger · npm · Webpack plugins
Ultra-fast file system watcher with native performance for Node.js development tools
@retrigger/core has 38 recorded weekly downloads on npm.
About @retrigger/core
@retrigger/core
Ultra-fast file system watcher with native performance for Node.js development tools
Replace slow JavaScript-based file watchers with native Rust performance. Get 100-400x faster hot reload times in your webpack and Vite projects.
🚀 Quick Start
npm install @retrigger/core
Webpack
// webpack.config.js
const { RetriggerWebpackPlugin } = require('@retrigger/core');
module.exports = {
plugins: [
new RetriggerWebpackPlugin({
watchPaths: ['./src', './config'],
verbose: process.env.NODE_ENV === 'development',
}),
],
};
Vite
// vite.config.js
import { createRetriggerVitePlugin } from '@retrigger/core';
export default {
plugins: [
createRetriggerVitePlugin({
watchPaths: ['./src'],
enableAdvancedHMR: true,
}),
],
};
📈 Performance
| Metric | Standard Watchers | Retrigger | Improvement |
|---|---|---|---|
| Hot reload latency | 500-2000ms | <5ms | 100-400x |
| CPU usage (idle) | 5-15% | <1% | 5-15x |
| Memory usage | 50-200MB | 10-30MB | 2-7x |
🛠️ Configuration
Webpack Plugin Options
new RetriggerWebpackPlugin({
// Directories to watch for changes
watchPaths: ['./src', './config'],
// Enable detailed logging
verbose: false,
// Debounce time for file events (ms)
debounceMs: 50,
// Enable Hot Module Replacement
enableHMR: true,
// Use SharedArrayBuffer for ultra-fast communication
useSharedBuffer: true,
// SharedArrayBuffer size (bytes)
sharedBufferSize: 2 * 1024 * 1024, // 2MB
// Maximum events to batch together
maxEventBatch: 200,
// Enable advanced dependency-aware invalidation
enableAdvancedInvalidation: true,
// Watch options
watchOptions: {
recursive: true,
exclude_patterns: [
'**/node_modules/**',
'**/.git/**',
'**/dist/**',
'**/build/**',
],
include_patterns: ['**/*.{js,jsx,ts,tsx,vue,svelte}'],
enable_hashing: true,
hash_block_size: 4096,
},
});
Vite Plugin Options
createRetriggerVitePlugin({
// Directories to watch
watchPaths: ['./src'],
// Enable verbose logging
verbose: false,
// Debounce time (ms) - lower for Vite
debounceMs: 10,
// Enable source map updates
enableSourceMapUpdate: true,
// Use SharedArrayBuffer for speed
useSharedBuffer: true,
// Enable advanced HMR with dependency tracking
enableAdvancedHMR: true,
// HMR invalidation strategy
hmrInvalidationStrategy: 'smart', // 'conservative' | 'smart' | 'aggressive'
// Watch options (same as webpack)
watchOptions: {
/* ... */
},
});
🎯 Features
Core Benefits
- Native Performance: Rust-powered file watching with SIMD-optimized hashing
- Zero Dependencies: No heavy JavaScript file watcher dependencies
- Cross-Platform: Works on Linux, macOS, and Windows
- TypeScript Support: Full TypeScript definitions included
- Graceful Degradation: Falls back to JavaScript mode if native components unavailable
Advanced Features
- SharedArrayBuffer Communication: Sub-millisecond event propagation
- Dependency-Aware Invalidation: Only rebuild what actually changed
- Performance Monitoring: Built-in metrics and optimization tracking
- Multiple Build Tool Support: Works with webpack, Vite, Rspack, and more
📊 Monitoring
Performance Stats Endpoint
When using the Vite plugin, access real-time stats at:
http://localhost:3000/__retrigger_stats- Basic performance metricshttp://localhost:3000/__retrigger_hmr_stats- Advanced HMR statistics
Programmatic Access
// Get performance statistics
const stats = await retriggerPlugin.getPerformanceStats();
console.log(`Events processed: ${stats.total_events}`);
console.log(`Average latency: ${stats.averageEventLatency}ms`);
🔧 Troubleshooting
Common Issues
High CPU Usage
// Reduce CPU usage by excluding more directories
new RetriggerWebpackPlugin({
watchOptions: {
exclude_patterns: [
'**/node_modules/**',
'**/dist/**',
'**/coverage/**',
'**/.next/**',
'**/.nuxt/**',
],
},
});
Slow Initial Scan
// Disable hashing for faster startup
new RetriggerWebpackPlugin({
watchOptions: {
enable_hashing: false,
},
});
Memory Usage
// Reduce SharedArrayBuffer size
new RetriggerWebpackPlugin({
sharedBufferSize: 512 * 1024, // 512KB instead of 2MB
maxEventBatch: 50, // Process fewer events at once
});
📝 TypeScript
Full TypeScript support is included:
import {
RetriggerWebpackPlugin,
createRetriggerVitePlugin,
type FileEvent,
type WatchOptions,
} from '@retrigger/core';
const plugin = new RetriggerWebpackPlugin({
watchPaths: ['./src'],
verbose: true,
});
🏗️ Requirements
- Node.js: 16.0.0 or higher
- Operating System: Linux, macOS, or Windows
- Architecture: x64, ARM64 (Apple Silicon supported)
🤝 Contributing
This package is part of the larger Retrigger project. See the main repository for contribution guidelines.
📄 License
MIT License - see LICENSE file for details.
Made with ⚡ by developers, for developers who value performance.
Description from the npm listing.
- file-watcher
- webpack
- webpack-plugin
- vite
- vite-plugin
- hot-reload
- hmr
- native
- rust
- performance
- development-tools
- build-tools
- napi-rs
- fast
- watcher
- file-system
README badge
Show your rank in a README or on your website. The badge updates automatically.
Charts
Images: 30d · 1y · all time · 1600×900 dark
Adoption over time
7/30/90-day growth
Ranking history
Listing placement
Listing placement
Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.
Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.
Recent observations
Full history (1)Similar npm Webpack plugins plugins
All 20 @retrigger/core alternativesData source
Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.
Listing: https://www.npmjs.com/package/@retrigger/core. First seen Oct 22, 2026; last successful collection Oct 23, 2026. See the methodology.