Creating reusable plugins
After analyzing the most important aspects of the development of jQuery plugins, we are now ready to analyze an implementation that is used for something more than a simple demonstration. In order to create a really useful and reusable plugin, it must be designed such that its operations are not restricted by the demands of its original use case.
The most popular plugins, like the most useful jQuery methods, are those that provide a high degree of configuration of their functionality. Creating a plugin that is configurable adds a degree of flexibility to its implementation, which enables us to match the needs of several other use cases that are governed by the same operation principles.
As we said earlier, a jQuery plugin ...
Get jQuery Design Patterns now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.