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.

Show HN: Build your first real world React.js application

261 pointsby mxstbrover 8 years ago

5 comments

pavlovover 8 years ago
Nice tutorials. I&#x27;ve been playing around with React, and I like it overall... But I can&#x27;t wrap my head around Redux. Could someone explain it to me so I might finally see the light?<p>My problem is this: I just can&#x27;t understand why I&#x27;d want to manipulate state in an unsightly switch statement like this one from Chapter 4 of the original post:<p><pre><code> switch (action.type) { case &#x27;CHANGE_LOCATION&#x27;: return Object.assign({}, state, { location: action.location }); case &#x27;SET_SELECTED_TEMP&#x27;: return Object.assign({}, state, { selected: { temp: action.temp, date: state.selected.date } }); case &#x27;SET_SELECTED_DATE&#x27;: return Object.assign({}, state, { selected: { date: action.date, temp: state.selected.temp } }); default: return state; } </code></pre> This reminds me of Win32 event loops with their window message handler switches... And that&#x27;s a scary association.<p>What&#x27;s the point with dispatching these fragile &quot;stringly-typed&quot; selectors, when you can just have real functions doing setState() updates on the relevant component?<p>I&#x27;m not trying to be snarky -- I know I&#x27;m missing something major here.
评论 #12446039 未加载
评论 #12448948 未加载
评论 #12446420 未加载
评论 #12445982 未加载
评论 #12446408 未加载
评论 #12446070 未加载
评论 #12446917 未加载
评论 #12445946 未加载
评论 #12446226 未加载
评论 #12448829 未加载
评论 #12448410 未加载
acemarkeover 8 years ago
Surprisingly few comments so far. My take: Max Stoiber is a fantastic contributor to the React ecosystem. His React-Boilerplate project is a solid, well-designed starting point for production application development. This new tutorial is well written, makes good use of the new Create-React-App tool to simplify the learning curve, and covers several topics in good depth to get someone started.
jcofflandover 8 years ago
I find I am more productive with vue.js. It is much less intrusive on my coding style. I believe react.js is mainly popular because of FB&#x27;s support. Much in the same way Angular became so widely used due to Google backing. I too have fallen for the myth that Open-Source projects backed by huge companies are always better. Do your homework. Don&#x27;t believe the hype.
评论 #12450529 未加载
primaryobjectsover 8 years ago
I just went through the first tutorial and it&#x27;s well written. However, I just had to try it with AngularJs and jQuery as well. Here are the results <a href="http:&#x2F;&#x2F;goo.gl&#x2F;V0NvkC" rel="nofollow">http:&#x2F;&#x2F;goo.gl&#x2F;V0NvkC</a><p>In such a simple example, I think jquery wins. However, more complicated solutions might be better suited towards frameworks like Angular and React.
评论 #12452111 未加载
omnivoreover 8 years ago
What I like that you&#x27;ve done is that start CTA in the right nav menu. Not just that it&#x27;s action oriented it just made me feel like I could start&#x2F;play around post-login without having to deal with a lot of redtape just to start using it.<p>Which for any new tool is important. Good luck.