TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Reduce ajax requests to one-line with jquery-ahm

29 点作者 jimsteinhart大约 14 年前

6 条评论

vmind大约 14 年前
This just looks like a great way to make your back-end depend on your front-end. AJAX calls are usually best served in an API like manner (here's some data, do what you like). This lets you iterate on the client without messing with the server, which this would destroy. If you have an application style client, you're also probably making the same data requests for different purposes.<p>Granted it's quite neat, but it seems like a bad idea. I think too many libraries recently are focusing on length of code to the detriment of good principles and clarity.
Klonoar大约 14 年前
Keep client side code exactly that: client side. If you're trying to do a separation like this, you clearly have no clue the hell you're going to get yourself into.<p>I'd suggest going back and reviewing the concepts of "graceful degradation"; for large scale web applications where this doesn't really apply, you'll quickly find yourself wanting the code streamlined and in <i>one place</i>.
BasDirks大约 14 年前
I'd like to keep my callbacks where they belong.
neilalbrock大约 14 年前
I really think this project is misguided. The idea that the responses from my data layer should also contain the code which is executed to present it client-side, well it's just plain wrong. The two should never be so tightly coupled.
denysonique大约 14 年前
Ahm! Looking forward to a Rails Gem hack of this plugin.
评论 #2418912 未加载
itsnotvalid大约 14 年前
Any revision controlled source tree for this plugin?