Dabby.js 0.9.7
This release fixes a number of bugs to make the output more stable and improve compatibility with jQuery. It also moves the documentation around a little to make it easier to use when looking through the repository. Some methods were added and some removed:
- Fixed bug in $.fn.attr() where it was handling the input attributes as an array instead of an object.
- Split
$.fn.on() and $ .fn.off() into different files. - Update $() to create a dabby object at the end, and send it raw nodes, which are then handled first, which creates a more efficient path through the function and uses less code
- Fixed issues in $.fn.trigger() where the native event wasn't called, and to make a special case for the submit event, where when triggered it doesn't fire any attached event handlers. It now uses a custom event to do this
- Fixed issues with radio boxes in $.fn.val() where it should return the value of the item requested, not the currently selected value, it also now only sets the value where the object is in the collection
- Updated $.fn.serialize() to select only checked radio and checkbox controls
- $.param() can now handle a function as a value and handles null's correctly
- Fixed bug in setCss() where the properties were not processed correctly
- Fixed bug in $.map() where the callback return value was not set properly
- Updated $.map() to support the callback returning an array
- Fixed bug in $.fn.attr() where it did not support using a callback as the value
- Fixed bug in $.each() where the keys returned from an array were strings instead of numbers. Fixes #4
- Fixed #3 where $.fn.toggleClass() didn't support the state parameter
- Fixed bug in $.fn.prop() where the gathered values were assigned to an array instead of an object
- Fixed bugs in $.fn.parentsUntil() where it returned the matching element, and didn't filter the nodes correctly
- core.js now doesn't include $.fn.attr(), it must be included manually if needed to create nodes with properties
- Removed $.isArray(), use Array.isArray() instead
- Updated getVal() to calculate the values for all objects in a collection and return an array, and then updated all usages. This is to enable all the property reads to be done before writes and limit layout thrashing
- Fixed some missing dependencies
- Added
$.fn.show(), $ .fn.hide(), and $.fn.toggle() - Added tests for
$.each(), $ .fn.closest() and $.fn.parentsUntil() - Added more tests to getVal()
- Added documentation for
$.fn.removeProp() and $ .fn.val() - Various code size optimisations