Live data from Hacker News

Ask HN: ReactJS – Do you use it? Do you like it?

news.ycombinator.com

31–40 of 78 posts

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#32
post #9

I used it for a project, along with a simple Flux implementation, and it did the job well enough. The declarative, state-based aspect of it is great. This might be a small thing, but I also missed their unified onChange event when I moved to another tool. I didn't really like JSX, though, and using straight-up JS to declare components is gross. Using React in general also seemed rather verbose, and I found myself dig…

I agree on the JSX point, but there are a few libraries that make using plain JS less awkward:

https://github.com/af/JSnoX https://github.com/mlmorg/react-hyperscript https://github.com/jussi-kalliokoski/react-no-jsx

I do wish the React team made their plain JS API less of a "second class citizen" to JSX though.

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#33
post #17
post #15

Earlier quoted context omitted.

I am using React for a smaller enterprise application and find it quite difficult to reason about. But perhaps it's not well suited to deeply nested forms with lots of fields. After about six months, I finally feel like I've got a handle on how it works, sort of. It's probably not something I'll use again on future projects though.

I feel like you lose out on using React if your application isn't going to be huge in terms of "components" and states. You're probably better off using simple_form and Turbolinks with Rails.

A better alternative in my experience is to implement just the unidirectional data flow idea. This gives you some of the advantages of react without a lot of the complexity.

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#34

I use it, am very happy with it. Use npm for client and server. Modular design, and uni directional data flow makes project management better than ever. #1 complaint is that watching with grunt react-browserfiy-ing the code buts a 3-15 second complile delay into my dev process.

You need to jump on that webpack train with react hot loader. No turning back. Here's a great boilerplate. https://github.com/cesarandreu/web-app

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#35
I use it at work and for personal projects. It's great, creating sophisticated interactions is a lot simpler with flux and react.

Flux is very boilerplate-y, even with some of the lighter frameworks. But boilerplate isn't particularly complicated, so you get over it.

If I were going to a hackathon I would not use flux+react, I'd probably go with angular. If it's something I plan on maintaining over a long period of time, react is currently my big choice.

Testing react is very nice, especially coming from angular where testing directives was very painful. (And testing everything else was needlessly verbose.)

I made a VERY simple project starter [0] that I'm going to take the chance to plug now. It's built for frontend web applications in mind, and it focuses on giving you the starting environment to build an app. It provides development, testing, and production builds. In development you get live-reload and hot-loading of assets. In production you get minification, concatenation, and cache busting of assets, as well as getting all assets copied to your output folder. There's a live testing environment (i.e. watch files and run tests) as well as a single-run environment. Tests also generate code coverage reports. The best part is that it doesn't use gulp or grunt, it's just a webpack config with a few flags per environment type, and to run every task you just use npm run-scripts. Out of the box it handles ES6/ES7/JSX, CSS, images and fonts, but extending it to support other assets is trivial. I took the time to heavily comment the webpack config in order to help people out.

EDIT: My coworker pestered me to edit this and mention that we're hiring [1]. If you're interested in using React and Flux, reach out!

[0] https://github.com/cesarandreu/web-app

[1] http://www.treasuredata.com/careers

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#36
I've been slowly injecting it into a project that was previously all JS + jQuery.

Things I love:

- All of the view state, event handlers, and markup in a single place. This makes it super easy to reason about.

- Very easy to learn and get up to speed with relative to a full framework. I found it even easier than Knockout which is saying a lot.

- Injectable into a pre-existing project that was not designed around using ReactJS.

Things that have bugged me:

- Having to add a JSX build step (yes I know you can avoid JSX but it's ugly)

- No standard Flux implementation the community can rally around

- There is a big community focus on utilizing bleeding edge front-end tech such as ES6 (using Babel) and CommonJS (through browserify/webpack), all installed through NPM. Even the FB Flux reference implementation is written in ES6. As someone crawling away slowly from simple jQuery based site, adding a full on front-end stack + ES6 is a huge ask.

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#37
Short answer: it's great.

I don't mean to echo the already loud voices of people championing React, but they're right: it's just awesome to write.

I think React has the right abstractions for today's web development: I am frequently able to express complex UI with very little SLOC. It's easy to see what a component does, and it's easy to jump into a project with little to no experience.

On that last point: I write software on a team with a lot of Angular.js fans. I've been trying to use React in more places, so I frequently start internal tools that have UI associated with them by using React.

It's going pretty well.

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#38
post #26

I'm stuck in the middle right now with dependencies on jQuery for existing projects, while trying to learn both React and AngularJS. I've also been experimenting with Vue.js which seems like a nice middle ground between React and Angular. I am also wondering if it's just better to wait for Angular2 before fully-deciding either way. There is also a strong argument to be made for Polymer + Web Components as the better…

I've wrapped a few jQuery plugins into a React components and had no issues or pain. YRMV.

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#39

I've been slowly injecting it into a project that was previously all JS + jQuery. Things I love: - All of the view state, event handlers, and markup in a single place. This makes it super easy to reason about. - Very easy to learn and get up to speed with relative to a full framework. I found it even easier than Knockout which is saying a lot. - Injectable into a pre-existing project that was not designed around usin…

You're the target of this repo [0] that I put up! It's meant to give you a complete environment for building a frontend application. I just wrote a comment [1] explaining some of the features it provides.

[0] https://github.com/cesarandreu/web-app/ [1] https://news.ycombinator.com/item?id=9751949

Re: Ask HN: ReactJS – Do you use it? Do you like it?

#40
Our front end developer seems to like it. We decided to use React in combo with RxJS[2], utilizing a unidirectional data flow for a new project[1]. React plays well with D3 and local CSS[3] to create reusable charting components. Our app produces a relatively high number of objects in a "table". The results would otherwise be paginated from here to oblivion and back to make it usable. Lazy rendering the results does the trick in our case.

So far we feel that Reactive Programming allows us to iterate quickly and swap parts of the back end rather easily, because, quite honestly, we don't know exactly yet where this journey is going to take us. We develop based on user feedback and the data we gather from them.

[1] https://keywordbrain.com (Preview of the front end is outdated)

[2] https://github.com/Reactive-Extensions/RxJS

[3] https://medium.com/seek-ui-engineering/the-end-of-global-css...

[4] https://gist.github.com/staltz/868e7e9bc2a7b8c1f754 (Good primer on Reactive Programming)

Post reply on HN