TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Drop jQuery as a dependency from Rails

292 pointsby robermirandaalmost 9 years ago

11 comments

stevepikealmost 9 years ago
The github thread itself is a nice example of a vibrant open source community. They're thinking about whether the project can be a good entry point for others into OSS, considering adopting outside libraries rather than re-writing it themselves, and generally operating in a pretty positive manner.
评论 #11816345 未加载
monk_e_boyalmost 9 years ago
As a web dev for the last 15 years or so, this is amazing news. The browsers are finally getting to a point where the pain jQuery solved, is going away.
评论 #11814087 未加载
评论 #11814341 未加载
评论 #11814011 未加载
jacobsenscottalmost 9 years ago
For everyone who thinks rails installs too much by default, and hasn&#x27;t ever tried `rails -h` - here are some options:<p>--skip-gemfile --skip-git --skip-keeps --skip-active-record --skip-sprockets --skip-spring --skip-javascript --skip-turbolinks --skip-test-unit
评论 #11816261 未加载
spriggan3almost 9 years ago
Rails should stop messing with Javascript all together. Drop JQuery, CoffeeScript, TurboLinks and what not and let the users decide what to use, make it optional. Rails shouldn&#x27;t require a JS engine in order to run.
评论 #11814018 未加载
评论 #11814027 未加载
评论 #11814069 未加载
评论 #11814031 未加载
评论 #11814323 未加载
评论 #11814410 未加载
评论 #11814869 未加载
评论 #11814469 未加载
评论 #11814137 未加载
评论 #11814039 未加载
评论 #11814540 未加载
评论 #11814611 未加载
评论 #11814669 未加载
Gonzihalmost 9 years ago
I never understood why rails has javascript helpers at all. It just does not bring any value in the long run, just complicates stuff. Rails should be js libraries agnostic and not provide any js related helpers out of the box in my opinion.
评论 #11817550 未加载
评论 #11815472 未加载
评论 #11814915 未加载
评论 #11814397 未加载
kendallparkalmost 9 years ago
So I did this in my own recent project. Then other JS libraries I was using needed jquery and it went right back in. I think many people will run into this.<p>I do agree that it should get out of default Rails. GJ community.
stephenralmost 9 years ago
There was an article about a week ago that makes the claim that Rails is tailor-made for Basecamp.<p>This single comment absolutely confirms that point of view: <a href="https:&#x2F;&#x2F;github.com&#x2F;rails&#x2F;rails&#x2F;issues&#x2F;25208#issuecomment-222980490" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;rails&#x2F;rails&#x2F;issues&#x2F;25208#issuecomment-222...</a>
评论 #11814947 未加载
评论 #11814624 未加载
评论 #11814576 未加载
评论 #11815400 未加载
tlrobinsonalmost 9 years ago
Related: <a href="http:&#x2F;&#x2F;youmightnotneedjquery.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;youmightnotneedjquery.com&#x2F;</a>
aphextronalmost 9 years ago
An irrelevant framework drops another irrelevant framework as a dependency.
applecorealmost 9 years ago
<i>Omakase</i> implies a certain level of excellence in all the individual choices.<p>I believe Rails is In-N-Out Burger. While it offers few choices, it&#x27;s reliable and the hamburger is very good. The fries and frontend framework are acceptable but no one goes to In-N-Out for the fries.
评论 #11815908 未加载
评论 #11814263 未加载
评论 #11814681 未加载
评论 #11814473 未加载
评论 #11814381 未加载
评论 #11814792 未加载
评论 #11814797 未加载
tacosalmost 9 years ago
Someone in DHH&#x27;s position could approach jQuery and request a subset containing what he needs. And then other projects could benefit from the refactor.<p>If there&#x27;s even a benefit. This same post by the leader of any other project would involve a study of which components and apps use jQuery. And would state how far back compatibility is to be maintained.<p>So, for example, if commonly used gems require it, or if 90+% of the rails apps in the field require jQuery for other reasons, then this is just code churn for no benefit.<p>And why is this even a &quot;rewrite&quot;? You can suck the relevant lines of code out of jQuery and call it done. This is not a &quot;Summer of Code&quot; length endeavor.
评论 #11814154 未加载