Re: [jquery-omaha] Any other jQuery + Rails developers out there?

From: Jerod S.
Sent on: Wednesday, January 20, 2010 7:52 AM
Rails is pretty opinionated about its conventions so I can see why they went with constants for defaults (especially since it is dead simple to include arbitrary JavaScript files using javascript_include_tag, or write your own helper method).

Constants aren't immutable in Ruby. In the SO thread you mention that you tried overriding the constants in an initializer but received a warning when booting your app. Warnings aren't errors, so if you really want to do this, go for it. Your app will still work and your :defaults will be overridden.

Hope that helps.

ps - jQuery 1.4 ftw. Great release!

Jerod Santo
http://jerodsanto.net


On Wed, Jan 20, 2010 at 12:26 AM, Adam Lassek <[address removed]> wrote:
I guess I'm just finding it hard to believe they would implement such a bad design as hard-coded values for something that should be interchangeable. But I don't want to get too offtopic, thanks anyway :)

On Tue, Jan 19, 2010 at 7:50 PM, Jerod Santo <[address removed]> wrote:
I have to agree with the first answerer on that thread. You are not using Rails defaults so simply don't use the :defaults argument.

Why hack the framework code to override the defaults when there is a very easy and appropriate method of loading jquery already available?

-- Jerod Santo

On Jan 19, 2010, at 7:26 PM, Adam Lassek <[address removed]> wrote:

Have you ever figured out a solution to this issue?



--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by Adam Lassek ([address removed]) from jQuery.
To learn more about Adam Lassek, visit his/her member profile
To unsubscribe or to update your mailing list settings, click here

Meetup Inc. PO Box 4668 #37895 New York, New York[masked] | [address removed]




--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by Jerod Santo ([address removed]) from jQuery.
To learn more about Jerod Santo, visit his/her member profile

To unsubscribe or to update your mailing list settings, click here

Meetup Inc. PO Box 4668 #37895 New York, New York[masked] | [address removed]





--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by Adam Lassek ([address removed]) from jQuery.
To learn more about Adam Lassek, visit his/her member profile
To unsubscribe or to update your mailing list settings, click here

Meetup Inc. PO Box 4668 #37895 New York, New York[masked] | [address removed]

People in this
Meetup are also in:

Sign up

Meetup members, Log in

By clicking "Sign up" or "Sign up using Facebook", you confirm that you accept our Terms of Service & Privacy Policy