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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Ask HN: Which JavaScript framework should a beginner chose?

2 点作者 lnk2w将近 10 年前
I&#x27;m learning web development right now, and every time I search for a framework or library I get lost in how many options I have. So far what I got is:<p>Angular: Google&#x27;s framework, is the framework teached by freeCodeCamp.<p>React: New kid on the block, made by facebook. People seems to like.<p>Ember + Handlebars: Some people said that is better than Angular.<p>Backbonejs: All I know is that is teached by The Odin Project.<p>For someone who is starting, after JS which framework should I choose.

4 条评论

spankalee将近 10 年前
I&#x27;m biased because I work on Polymer, but I&#x27;d say.... No framework - use custom elements.<p>Frameworks tie you into their silo, which is different and isolated from all the others. This is a terrible situation for developers (and ultimately users as dev effort is wasted duplicating things for each framework).<p>Custom elements are a way to define your own HTML tags. These work like other elements: they have attributes, events, child nodes and properties. They can be placed on a simple static web page, or wired together into complex apps. Elements are (mostly<i>) naturally interoperable with other elements and even the plethora of frameworks.<p>Where Polymer fits in is that it&#x27;s a library that help you write custom elements with support for templates, marshaling attributes, data-binding, etc. as well as some polyfills for web component standards.<p>It&#x27;s very useful, IMO, but the real beauty is that Polymer elements don&#x27;t</i> leak to the outside that they&#x27;re made with Polymer - they&#x27;re just elements. If you use another custom element framework you can still use Polymer-made elements.<p>* The big caveat is this thing called Shadow DOM which is hard to polyfill. Polymer uses a near-polyfill called Shady DOM that can be important to use in some situations. It&#x27;s still possible to interop with other frameworks with some configuration though.
skadamat将近 10 年前
I would hold off on any of these and actually work with vanilla JS + some jQuery. Once you outgrow those, THEN move to one of the above. The first 25% of most web apps won&#x27;t need need anything past plain old Javascript and some jQuery. IMO it&#x27;s better to learn the framework only when you out-grow the basic beginning tools, that way you also have a greater appreciation for the philosophy behind why some of these frameworks emerged.
rndywcks将近 10 年前
If you&#x27;re just beginning, and don&#x27;t have a particular need for any one framework, I&#x27;d say go with Angular. It&#x27;s by far the most widely used and popular of the choices (using github stars, # of modules, stackoverflow questions, github contributors, and github forks as indicators).
vdaniuk将近 10 年前
You&#x27;re learning, there is no practical benefit in limiting yourself just to one framework.<p>Spend at least several weeks at learning all of them: Angular 2, Ember 2 and React. Learning by comparison will be much more beneficial for your understanding than doubling down on one framework.