Live data from Hacker News

React Tutorial: Cloning Yelp

fullstackreact.com

41–50 of 258 posts

Re: React Tutorial: Cloning Yelp

#41
post #3

To me this epitomizes what I feel as I'm trying to explore options for different front-end frameworks. In this article I'm 30 screens down (literally 30 page down presses) and it's not even finished setting up the environment and dependencies. Sure, this is something that you only do once, so if it then leads to much better development workflow it makes sense to have a solid investment upfront, but it makes it very h…

I also share your frustration.

I am learning react. A few weeks ago I wrote a small app and based my work from a starterkit with a few thousand stars on github. I learned a lot from this app and the starterkit.

This week I decided to use what I learned at work, writing a small app that will be used only internally. When I cloned the same project at least 15-20% of the project was different.

Not just is a pain to set up a project but it's also changing very fast.

Re: React Tutorial: Cloning Yelp

#44
post #3

To me this epitomizes what I feel as I'm trying to explore options for different front-end frameworks. In this article I'm 30 screens down (literally 30 page down presses) and it's not even finished setting up the environment and dependencies. Sure, this is something that you only do once, so if it then leads to much better development workflow it makes sense to have a solid investment upfront, but it makes it very h…

I feel the same frustration even though I am still at a point where I generally have a huge tolerance for this kind of stuff.

Slowly, however, things seem to be improving.

For one, Redux seems to be the preferred 'flux implementation'; that's an improvement over the countless implementations I had to choose from when I started about a year or two ago.

Then there are Rich Harris' Buble[1] and Rollup[2], which provide respectively batteries-included ES2015 transpiling and module bundling, and probably a bunch of other projects I'm not aware of that provide some sort of standardization or simplification in this process.

It's not happening as fast as I'd like, but it seems to be a move in the right direction.

[1]: https://gitlab.com/Rich-Harris/buble [2]: http://rollupjs.org/

Re: React Tutorial: Cloning Yelp

#45
post #40

Great work on the tutorial. I'm sure it took a lot of time to setup, and it seems well written. However I simply won't believe that setting up a simple React app requires so much overhead. Granted, I have no experience with React, and only marginal experience with frontend web dev. As I read the tutorial, this is the list of questions I had: 1. Why do we need so many Babel presets? What do they do? 2. Why do we need…

Exact same feeling here, well put. I recently started Tyler McGinnis' excellent React.js Fundamentals and the entire first section of the course is setting up Webpack, Babel, etc. Once you're set up there, then you need to decide how you'll handle routing, AJAX - and so on.

The older I get the more I hate third party dependencies. You're asking for trouble.

Re: React Tutorial: Cloning Yelp

#46
post #38
post #13

Earlier quoted context omitted.

I've shared your frustration. The Hello World experience is a huge spectrum ranging from the 30 screens of setup you describe to the one-click Visual Studio installer. The other thing to consider is what you assume from a reader in a tutorial. If you assume they have a full environment setup (or will be following another tutorial), you can put together a much more concise article. Imagine the now-classic Rails Blog i…

I really feel like this isn't a general problem, but rather a problem with a subset of development environments. Node (backend) definitely doesn't have a similar problem. Want an express app? Install node -> npm i express --save -> node app.js. Go doesn't have it either, whether you're using the base tool or GVM. Python requires a minuscule setup in virtualenv, but beyond that its straightforward. Elixir and Rust are…

To be fair, the parent to your comment included lots of steps that assumed the user was starting from scratch. If we assume the same for the user making an Express app, the steps are much more complex:

* Install a C++ compiler (XCode or libssl-dev packages)

* Run the NVM install script

* Use NVM to install Node.js

* npm install express-generator -g

* express myapp

* cd myapp; npm install

* Install or update Homebrew

* Install git

* git init

* Install Mongo (or your db of choice)

* Install Mongo packages via npm

* npm start

Re: React Tutorial: Cloning Yelp

#47
post #17

Earlier quoted context omitted.

> the same frustrations when I was looking at things like meteor The main strength of Meteor is the speed you can get up and running $ meteor create my-app-name $ meteor npm install $ meteor will set you up with a full stack application, running locally, with zero config

The thing is with Meteor I feel like I have to learn ALL of meteor to really expand/extend upon what it gives me or use some plugin, it feels like it takes away way too much control for me. With Angular I feel like I have to re-learn web development and do everything the "angular way", and who knows when Angular three comes out and the "Angular way" completely changes. With React, I can learn a small framework that's…

> I don't feel like I have to re-learn everything I know about web-dev when using react like I do with Angular.

I find it odd that you feel that way given nearly every React tutorial absolutely does do things the "react way" including using mostly the same toolset.

Things like Flux, GraphQL, "Higher-order components" are not general web-dev knowledge you already have. React has it's own language, as much so as any other framework I've encountered.

Re: React Tutorial: Cloning Yelp

#48
I'm no Javascript Boilerplate Fatigue apologist, but there are many comments in here that are treating this as a "Learn how to use React" tutorial. This is not what is advertised nor the stated reason this article was written.

From the first sentence: "we get a lot of questions about how to build large applications with React and how to integrate external APIs" Large application strucutre, external integrations...not "Hello World"

Of course there is no need for multiple environments, or a robust testing setup, or an icon font, or 6 different webpack loaders to learn the basics of React. This is not a tutorial on the basics of React -- this is written from the perspective of a large production level application. And that "overhead" and "insanity" are helpful for real projects that are staffed by more than one person and need to last more than a week.

It seems absurd that it might take you 2 hours to setup the environment before you get to hello world. But if you are planning to use this as the foundation of a 6 month long project, 2 hours to get everything setup in a sane way is not an issue.

There is absolutely churn in the JS world and some of it does seem unbelievable because things haven't contracted and settled into a steady-state. But don't just levy a blanket "lol fuck javascript tooling" every time you see a complicated setup process; you are doing yourself a disservice by not critically evaluating the choices the author of this post made and determining for yourself if they will benefit your project and/or learning efforts.

Re: React Tutorial: Cloning Yelp

#49
post #40

Great work on the tutorial. I'm sure it took a lot of time to setup, and it seems well written. However I simply won't believe that setting up a simple React app requires so much overhead. Granted, I have no experience with React, and only marginal experience with frontend web dev. As I read the tutorial, this is the list of questions I had: 1. Why do we need so many Babel presets? What do they do? 2. Why do we need…

Check out DoneJS which gives you everything you need: https://donejs.com/Guide.html

  donejs add app my-app
  cd my-app
  donejs develop
A full environment with hot module swapping included, code-splitting for production builds, etc. No configuration required.

Re: React Tutorial: Cloning Yelp

#50
People should stop complaining about how "hard" it is to get started or how "complicated" React is.

React is simple. Its core abstraction is trivial (making views into pure functions).

If you want to, you can get started with React today without installing any software at all. Just include it from the CDN: https://cdnjs.com/libraries/react/

The rest is there because things like live-reloading are genuinely helpful. But you don't need to roll them yourself. There are dozens of great boilerplates you can base a new project off of.

Also, I've never had as much difficulty setting up a React environment as the constant struggle it is to get even a basic Java app to build from source.

Post reply on HN