-
Notifications
You must be signed in to change notification settings - Fork 75
Conversation
@asppsa actually what you describe as "another way" would be the correct way. Passing in the
|
@skeptic35, are you saying that the fix in 73eed26 generates the error you describe? It seems to be working for me, although I'm JSPM rather than RequireJS. |
@asppsa yup - that's what I'm saying. Don't know why it is working for you because it actually doesn't have anything to do with RequireJS, it's just how javascript works.
calls the
doesn't call the function and instead passes the function itself to I have to apologize though for the suggested solution. Was in a bit of a hurry, so I didn't really think this through.
In short: Just make sure the |
P.S. - come to think of it - maybe it does have to do with using RequireJS. Dunno how JSPM works, but RequireJS calls the function passed to |
@skeptic35, my PR changed line 11 from |
Oops - you're right - it did. That's kind of embarassing - sorry. |
No need to apologise! I was definitely not sure about my patch, so I am glad someone using requirejs can test things out. I think the issue is that there has not been a new release since the PR was merged. You could perhaps try installing from git instead of and see if that works. |
I kinda did that already ;) - works |
define
function is supposed to have as its second argument a function that will be called, passing in the module's dependencies. I guess another way to do this would bedefine([], function() { return factory(plugin); });
, if it is necessary to pass thatplugin
variable in still.