-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: d.select2 is not a function #40
Comments
I'm sorry, but I'll need more info to debug this. Can you make a minimal
|
Hi Ruben, thanks for the quick reply. Here the fiddle: https://jsfiddle.net/didadan/wLb6jc7p/1/ |
Ups, guess it was the wrong link. Had to make it public first: https://jsfiddle.net/didadan/wLb6jc7p/ |
There's no jQuery nor select2 loaded in that fiddle, that clearly won't work :-) |
Ok, I didn't put it because it's not mentioned in the documentation - at least I didn't find it. However I tried with different solutions, here is a fiddle with the libs. How about this? https://jsfiddle.net/didadan/nzw6ybmt/ |
Try loading jQuery before loading Angular, when combining those you always need to load jQuery first. |
Thank you Ruben, that solves the issue. |
Hi Ruben, this might be similar to #39.
I followed your instruction and used the current version. It always brings up the same error. Do you have any clue what could cause this?
Versions:
Angular: 1.4.7
rubenv/angular-select2: 1.4.3 and 1.4.2
(with and without select2: 3.5.4, 3.5.2 and 4.0.2)
Basically the code is: angular module:
'rt.select2'
<select2 ng-model="obj.field" s2-options="val.id as val.name for val in values" options="{ allowClear: true }"></select2>
The text was updated successfully, but these errors were encountered: