What problem does it solve?
jQuery remains a common foundation for many legacy and plugin-based projects. These guidelines help teams write clean, maintainable, and performant jQuery code while balancing modern JavaScript preferences.
Core Features & Use Cases
- Module patterns and namespace discipline: structure code to avoid global pollution and improve testability.
- Selectors, DOM manipulation, and events: baseline patterns for efficient querying, minimal reflows, and robust event handling.
- AJAX, plugins, and migration strategies: guidance for safe AJAX usage, plugin development, and migrating to vanilla JS where appropriate.
- Performance, testing, security, and anti-patterns: practical tips to prevent common slowdowns and security issues in jQuery code.
- Use case: refactor a legacy jQuery module into a modular, testable component with clear public API and minimal DOM interactions.
Quick Start
Refactor the legacy jQuery module to a modular pattern with a named namespace and a single entry point for initialization.