trentrichardson / jQuery-Timepicker-Addon

Adds a timepicker to jQueryUI Datepicker
http://trentrichardson.com/examples/timepicker/
MIT License
2.66k stars 1.05k forks source link

Proper way to destroy DOM elements, event registrations, and other memory resources #729

Open Scottmitch opened 10 years ago

Scottmitch commented 10 years ago

What is the proper way to destroy() resources for this plugin? I am scrubbing some JS code which uses this plugin and noticed there is no destroy() or other cleanup type calls made for this plugin. I also can not find any thing in the code, options, and I haven't found a proper API documentation to reference.

I attempted to setup a fiddle to demonstrate if there were memory leaks or not but pulling in JQuery UI was attempting to reference http://example.com/error.js which resulted in a 404 error. I also had to directly inject this plugin's CSS and JS because referencing the URLs returned 403 error codes.