RJS collection proxies are currently broken for mixed case methods like findAll or sortBy. I''ve added a patch in http://dev.rubyonrails.org/ticket/4314. In looking into the patch I was led to wonder if it might be useful to add an option :lower to camelize to generate lower camel case names? "my_name".camelize(:lower) #=> myName -- Cody Fauser http://www.codyfauser.com
On 3/19/06, Cody Fauser <codyfauser@gmail.com> wrote:> RJS collection proxies are currently broken for mixed case methods > like findAll or sortBy. I''ve added a patch in > http://dev.rubyonrails.org/ticket/4314. > > In looking into the patch I was led to wonder if it might be useful to > add an option :lower to camelize to generate lower camel case names? > > "my_name".camelize(:lower) #=> myName > > -- > Cody Fauser > http://www.codyfauser.com > _______________________________________________ > Rails-core mailing list > Rails-core@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails-core >#4314 is in. And because you''ve been such a great sport, #4194 is in too. Thanks for the patches. Some kind of option for camelizing javascript names is definitely needed as we get into more javascript generation. -- Rick Olson http://techno-weenie.net
Thanks Rick! On 3/19/06, Rick Olson <technoweenie@gmail.com> wrote:> On 3/19/06, Cody Fauser <codyfauser@gmail.com> wrote: > > RJS collection proxies are currently broken for mixed case methods > > like findAll or sortBy. I''ve added a patch in > > http://dev.rubyonrails.org/ticket/4314. > > > > In looking into the patch I was led to wonder if it might be useful to > > add an option :lower to camelize to generate lower camel case names? > > > > "my_name".camelize(:lower) #=> myName > > > > -- > > Cody Fauser > > http://www.codyfauser.com > > _______________________________________________ > > Rails-core mailing list > > Rails-core@lists.rubyonrails.org > > http://lists.rubyonrails.org/mailman/listinfo/rails-core > > > > #4314 is in. And because you''ve been such a great sport, #4194 is in too. > > Thanks for the patches. Some kind of option for camelizing javascript > names is definitely needed as we get into more javascript generation. > > -- > Rick Olson > http://techno-weenie.net > _______________________________________________ > Rails-core mailing list > Rails-core@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails-core >-- Cody Fauser http://www.codyfauser.com
> > "my_name".camelize(:lower) #=> myNameThis now works. -- David Heinemeier Hansson http://www.loudthinking.com -- Broadcasting Brain http://www.basecamphq.com -- Online project management http://www.backpackit.com -- Personal information manager http://www.rubyonrails.com -- Web-application framework