Closed anotherZero closed 10 years ago
Which version of jQuery do you use?
I'm using v2.1.0 currently.
Current issue is fixed by a latest commit. Thanks @anotherZero.
Note that you don't have to set these lines:
window.icheck = {
tap: true
};
$('.icheck').icheck({
checkboxClass: 'icheckbox_flat-blue',
checkedClass: 'checked'
});
They expand the default options, which are the same except the custom checkboxClass
option.
https://github.com/fronteed/iCheck/blob/2.x-beta/icheck.js#L18-L52
Instead, you can set this option using the data attribute:
<input type="checkbox" data-checkedClass="icheckbox_flat-blue" class="icheck" id="rememberMe" name="rememberMe" />
iCheck customizes all the .icheck
selector elements by default
https://github.com/fronteed/iCheck/blob/2.x-beta/icheck.js#L48
looks great, thanks!
I tried icheck 2.0rc1 again and I'm getting an error that crashes the icheck() function. The debug console says that line 341 is the problem.
I did my best to try to see what's wrong on this line, here's what I've found so far:
if I don't declare a window.icheck = {} object, then $.expando seems to be undefined $.cache is always undefined.
Here's my icheck setup