Val is restructured to support extension of getters/setters
Additions:
jQuery.fn.valHook( obj )
Override the default value getter/setter for the given elements
@param{Object} obj An object containing a get and/or a set function
jQuery.fn.removeValHook()
Remove the valHook from data and revert back to default.
checkValHooks( elem, type )
Private: checks for a special valHook for the given elem. Returns the hook or undefined.
@param{element} elem Node to check
@param{string} type "get" or "set"
jQuery.valHooks -- Object
Contains special getter for option nodes, special getter/setter for select elements,
and special getter/setter for radio/checkbox inputs
radioCheckVal -- Object Modularizes getter/setter for checkbox and radio inputs
Arguments For:
You can attach hooks to certain node types, as well as val hooks to any collection of elements using jQuery.fn.valHook
It will allow the jQuery UI dev team to add val methods for custom inputs such as datepickers, progressbars, and sliders so that you may simply call val() on these elements.
Modularizes the special getting and setting for options, selects, and radio/checkbox inputs (this can be done whether or not jQuery.fn.valHooks is added)
Plugins that javascript-replace checkboxes, radios, selects, etc. so they can be styled can utilize this to easily retrieve correct values.
Arguments Against: