News for hackers. Stuff that matters.
Re:React/JavaScript fatigue by thirdreplicator on Sunday December 27, 2015 @11:03PM (#10799791)
I was thinking to put React.js in my adopt circle, but I spent a couple of days setting up the Node.js gulp-vinyl-browserify-babelify nonsense, and it really is a witch's brew of configuration hocus pocus. Its compelling to know that React is backed by Facebook, but React is simply verbose and comes with too much stuff packed into one package.

Whats the alternative? Thanks to hacker news i bookmarked vuejs.org and finally got a chance to come back to it. I made a couple of pages with vue.js, and I think there is a lot less stuff to do. There's no JSX. Your HTML peppered with vue.js directives is your templating language. There's no server side rendering, but that may be a good thing in the end. Fewer dependencies, less learning curve, less ecosystem to swallow in a single gulp. I hired a fresh grad from the Philippines, and he was able to pick it up and run with it immediately. I've only been using vuejs over Christmas, but I'm looking forward to seeing what else it can do. I'll post a small PHP-backed CRUD app if people are interested.

Re:React/JavaScript fatigue by DCoder on Sunday December 27, 2015 @11:39PM (#10799896)
React can do strongly-typed views. I use Typescript, and I can build the DOM either in JSX or by nesting React.DOM.div() and friends, and the Typescript compiler will yell at me if I use an event handler/variable/etc. that does not exist in the code. Why would I go back to an opaque templating language after that?
Re:React/JavaScript fatigue by qaq on Sunday December 27, 2015 @11:17PM (#10799833)
It all depends. React as of right now is the only viable option that has decent server side rendering for 80%+ of web apps it's a must for SEO, FB integration etc. Until Angular 2.0 ships and Ember get's fastboot completed there is no other major viable option.
Re:React/JavaScript fatigue by MatthewPhillips on Sunday December 27, 2015 @11:20PM (#10799840)
DoneJS as well. It includes Web components, a browser module loader, and has the most complete server side rendering of any framework. https://www.google.com/url?sa=t&source=web&rct=j&url=http://...

http://donejs.com

Re:React/JavaScript fatigue by qaq on Sunday December 27, 2015 @11:26PM (#10799858)
by "major" I meant something that has recognizable market share.
Re:React/JavaScript fatigue by joshontheweb on Sunday December 27, 2015 @11:22PM (#10799846)
Im don't know a lot about SEO but afaik Google crawls javascript pages. Do you still take an SEO hit in that case?
Re:React/JavaScript fatigue by onewaystreet on Sunday December 27, 2015 @11:04PM (#10799794)
> gulp-vinyl-browserify-babelify nonsense

Use Webpack. It replaces the need for all of these and does a much better job.

Re:React/JavaScript fatigue by sergiotapia on Sunday December 27, 2015 @11:10PM (#10799813)
"Replace this garbage with this other newer garbage."
Re:React/JavaScript fatigue by pavel_lishin on Sunday December 27, 2015 @11:15PM (#10799825)
Doesn't that just glue them all together? We're using it at work, and we brought in an in-house React person, but I have no idea what the config does/signifies, and every time they change something, I absolutely don't understand why or how it works. (Our tests currently don't work. I mean, they can run - unless there's an error, in which case it exits early with a 0 status, without running any of the subsequent tests.)

This is partially on me - I should read the shit out of the docs - but so far it seems like it just paints over the complexity a little.

Re:React/JavaScript fatigue by pavel_lishin on Monday December 28, 2015 @04:05PM (#10803384)
Late update: read through some of the webpack source code. As near as I can tell, it completely ignores most of the options passed to it via the CLI. (For example, --colors seems to have zero effect on anything.)
Re:React/JavaScript fatigue by Touche on Sunday December 27, 2015 @11:08PM (#10799800)
After 300+ lines of config spread over 3 files.
Re:React/JavaScript fatigue by mbrock on Monday December 28, 2015 @02:45AM (#10800312)
What does all that stuff have to do with React? Isn't it just a bunch of general purpose JavaScript tools that you decided that you needed to use?
Re:React/JavaScript fatigue by thirdreplicator on Tuesday December 29, 2015 @09:41PM (#10810409)
Yeah you're right. I conflated the two issues in my comment.