This major release introduces a comprehensive Playwright test suite, reorganized event architecture, and complete CI/CD automation. The library now includes 210+ automated tests ensuring reliability across all supported events and browsers.
What's New
Comprehensive Test Suite
- Migrated from browser-based testing to Playwright with 210+ automated tests
- Added 13 specialized test files covering all event types, edge cases, and configurations
- Introduced visual test page (test/visual.html) for real-time event monitoring
- Cross-browser testing on Chromium, Firefox, and WebKit
- 100% coverage of all 113 DOM events
Enhanced Event Architecture
- Reorganized events into logical categories:
- nativeBubblingEvents (80 events)
- nativeCapturableEvents (13 events)
- nativeDelegatableEvents (92 events)
- nativeWindowEvents (113 events)
- Improved event registration logic for better performance
- More efficient event delegation and memory management
- Better debounce tracking with element-specific timeouts (no more false positives or collisions)
New Event Support & Features
- Fixed scroll event handling for nested elements - each scrollable element maintains independent debounce state
- Added support for newer DOM events:
- beforetoggle and toggle events for details elements
- scrollend event for detecting scroll completion
- contextlost and contextrestored for WebGL contexts
- Page transition events: pagereveal, pageshow, pageswap
- Perfect for modern UIs with infinite scroll, chat interfaces, and multi-pane layouts
CI/CD & Automation
- GitHub Actions workflows for automated testing, releases, and PR checks
- Automatic npm publishing on GitHub release creation
- Dependabot configuration for dependency updates
- Modern build configuration with minification, sourcemaps, and tree-shaking
Documentation Improvements
- Expanded README with detailed examples and use cases
- Added CONTRIBUTING.md with development guidelines
- Enhanced API documentation with all event categories
- Improved release instructions with proper git tagging workflow
Developer Experience
- Added development build script (build:dev) with inline sourcemaps
- Bundle analysis script (build:analyze) for size optimization
- Updated to modern browser targets (Chrome 90+, Firefox 88+, Safari 14+, Edge 90+)
- Prettier configuration migrated to .prettierrc.json
Backward Compatibility
This release maintains backward compatibility with v1.x. The public API is unchanged - all existing code will continue to work without modifications. Internal event categorization has been reorganized for better performance, but these changes are transparent to users.
Full Changelog: v1.0.2...v2.0.1