Return jQuery from module to get it work like original jQuery module #296

Open
wants to merge 1 commit into from

3 participants

@hauleth

No description provided.

@neerajdotname
Ruby on Rails member

@hauleth Can you elaborate on the change as to how it is useful.

@hauleth

When using RequireJS now this code:

require(['jquery_ujs'], function($) {});

Will not work as expected, after merge will.

@JangoSteve
Ruby on Rails member

I don't really use RequireJS in any projects, so I only have passing familiarity with it. Can you explain how this would normally be used, or more specifically why we'd want to return the jQuery object instead of the rails object? I.e. why wouldn't we instead want return rails; at the end?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment