Live data from Hacker News

Guide to JavaScript Frameworks

javascriptreport.com

231–240 of 244 posts

Re: Guide to JavaScript Frameworks

#231

Earlier quoted context omitted.

You cannot learn React in one day. No matter how clever you are. You can learn enough to start coding but, until you understand Redux, how to use selectors with Reselect, middlewares, async-actions and the component lifecycle, you will be writing awful code. Some people, when they pick a new technology, they choose to spend an afternoon reading half tutorial and then start coding straight away. By the time they final…

Even Dan the creator of Redux says you don't always need Redux and I got along fine without it for a basic app. I was writing clean React code within a day. The component lifecycle took maybe two days to understand? It's so simple I wrote a popular answer about lifecycle on Stackoverflow within a couple weeks of learning it. Want to write a big app with complex state? Sure, you'll want to add Redux to the mix. But it…

In order to be able to tell if you need Redux or not for a project, you need to know Redux; the pros and the cons.

IMHO, too many developers overestimate their intelligence and write awful code because they didn't take the time to learn well the tools.

Re: Guide to JavaScript Frameworks

#232

Earlier quoted context omitted.

Of course - just pop it in a script tag and use the React object functions to render your DOM (which is exactly what transpiled code does)

I've looked into Vue.js, and they seem to indicate that it's easier to get up an running than react (using what you describe here). Are you suggesting vue.js and react work exactly the same?

I don't know because I don't use Vue. What you'd be missing if you dropped in the react library and did no compilation at all is the ability to use JSX. I'm guessing vue's argument is their attribute tags still work in their minimal deployment whereas with React you'd be manually wiring up things to the React object functions.

So, with React, instead of:

    return My component!
You use:

    return React.createElement('div', {}, 'My component!);
Some people like the more implicit style anyways (although I don't and I don't know anybody who does at this point)

Re: Guide to JavaScript Frameworks

#233

Earlier quoted context omitted.

Even Dan the creator of Redux says you don't always need Redux and I got along fine without it for a basic app. I was writing clean React code within a day. The component lifecycle took maybe two days to understand? It's so simple I wrote a popular answer about lifecycle on Stackoverflow within a couple weeks of learning it. Want to write a big app with complex state? Sure, you'll want to add Redux to the mix. But it…

In order to be able to tell if you need Redux or not for a project, you need to know Redux; the pros and the cons. IMHO, too many developers overestimate their intelligence and write awful code because they didn't take the time to learn well the tools.

> In order to be able to tell if you need Redux or not for a project, you need to know Redux

Not according to the creator of Redux. His advice is "Instead learn to think in React. Come back to Redux if you find a real need for it, or if you want to try something new. But approach it with caution, just like you do with any highly opinionated tool."

https://medium.com/@dan_abramov/you-might-not-need-redux-be4...

> too many developers overestimate their intelligence and write awful code because they didn't take the time to learn well the tools

No argument there. You do have to go through the entire official tutorial, and I would also recommend the article "Thinking in React", that Dan Abramov referenced above. https://reactjs.org/docs/thinking-in-react.html

I'm not claiming your experience with awful code isn't real, I'm sure it is. But is it because React is difficult to learn? When I learned React I was already good at JavaScript. And I had already learned Angular. Angular took me over a month to start to feel comfortable, and I still felt like I was stumbling around in the dark. The Angular API is very big. With React I was writing code, and code that I still use, within days. And I felt comfortable that I mostly knew what I was doing. When my code got a little more complex, I took a few hours to read about and learn about Higher Order Components. And when I needed routing I taught myself React Router in one day, and began answering questions about it on StackOverflow shortly after. Did I take the time in each case to completely understand the API and is that different from what other devs are doing? Possibly. But the point is that the React API did not take me weeks to learn. It's a simple API and there just isn't much there to learn. The React lifecycle for example has less than a dozen methods. It's super simple. Maybe other devs do struggle with getting such a simple API internalized, or maybe they just didn't go through the entire tutorial carefully enough. With React Router I am constantly answering questions that have answers right in the documentation. So maybe what you are seeing is lazy programmers, not a difficult API. In any case, in the interest of not going around in circles here with a difference of opinion, my most important point was comparing the simplicity of learning a UI library (React) vs. a very complex framework like Angular. React was WAY more simple to learn in comparison. And it should be. It does far less. Fair?

Re: Guide to JavaScript Frameworks

#234

Earlier quoted context omitted.

These are exactly the same reasons that I think React is the best. Vue looks like it's going backwards compared to React. Furthermore, you get native mobile apps for free with React Native. Also, React has a much, much bigger community and bigger companies supporting it.

Not just mobile apps: Windows: https://github.com/Microsoft/react-native-windows Macos: https://github.com/ptmt/react-native-macos Linux (Qt): https://github.com/status-im/react-native-desktop AR: https://github.com/HippoAR/react-native-arkit VR: https://facebook.github.io/react-vr/ TV: https://github.com/react-tv/react-tv Shell consoles: https://github.com/Yomguithereal/react-blessed Word: https://github.com/nitin42…

wew dude o.o

Re: Guide to JavaScript Frameworks

#235
post #216
post #57

Earlier quoted context omitted.

I'd point out that often rare and often unused skills get higher pay due to simple supply and demand. I've heard similar salary ranges for Assembly programmers for example. Angular and React are widely used, and there are many people out there that know them. No need to pay a ton. > The problem with Ember is the learning curve because it doesn't usually let you take shortcuts. I'm guessing that's precisely one of the…

> Why train an entire dev team on it only to have half leave in a year Errr, Ember is the most stable of currently used JS frameworks. And generally this whole "change JS framework every year" meme is crazily overblown.

This is about how long people stay at the same job, not the framework stability. In my experience people hop from job to job often enough that you'd be regularly training people on a language unless they already knew it when hired. So a language that people already know or has a low learning curve is usually preferred for many companies.

Re: Guide to JavaScript Frameworks

#236

Earlier quoted context omitted.

Even Dan the creator of Redux says you don't always need Redux and I got along fine without it for a basic app. I was writing clean React code within a day. The component lifecycle took maybe two days to understand? It's so simple I wrote a popular answer about lifecycle on Stackoverflow within a couple weeks of learning it. Want to write a big app with complex state? Sure, you'll want to add Redux to the mix. But it…

In order to be able to tell if you need Redux or not for a project, you need to know Redux; the pros and the cons. IMHO, too many developers overestimate their intelligence and write awful code because they didn't take the time to learn well the tools.

Too late to edit my other response where I meant to point out that in React, Javascript is the templating language, which is one less thing to learn when compared with Angular and others if you already know JavaScript well.

Re: Guide to JavaScript Frameworks

#237

Earlier quoted context omitted.

Funny, I've worked with multiple companies and their lawyers who were very serious about license compliance and what not. It took all of fifteen minutes to prepare a spreadsheet of our licenses (planned, anyway). Not a complaint from any of them, other than an "oh, that's more than I'm used to seeing." The one sticking point was webpack 1; they had some dependencies with unlicensed dependencies. Fortunately, we were…

Fair enough. Now imagine that your product or service is gaining popularity on the market where Google or Facebook consider you a competition.

Considering that both Google and Facebook are heavily invested in this scene with Angular and React, there's not much to imagine. They're both fine with lots of licenses.

Re: Guide to JavaScript Frameworks

#238
post #98

Earlier quoted context omitted.

Ember isn't gone or anything close to it.

Not to be a jerk, but can you provide any links to large sites or apps that use Ember? Again,this is a serious question, as I like to keep tabs on trends for JS stuff like this.

Twitch, Microsoft Store, LinkedIn, Netflix, Digital Ocean

Re: Guide to JavaScript Frameworks

#239
post #198

Earlier quoted context omitted.

The official React tutorial starts you out by installing create-react-app. I know that vue has something similar and I wouldn't be surprised if others did as well (are there even other important front-end frameworks besides React/Angular/Vue at the moment?) https://reactjs.org/tutorial/tutorial.html This allow you to start off with a great setup and skip the configuration so you can get started with just writing Reac…

Case in point: Vue does have a vue-cli which is similar to create-react-app in intent. However, official vue guide starts with simple examples and jsfiddle[0] [0] https://vuejs.org/v2/guide/

The "Quick Start" section of React docs that introduces concepts one by one uses CodePen which is similar in spirit to JSFiddle.

https://reactjs.org/docs/hello-world.html

Post reply on HN