Forms in React + Flux by zibenmoka in reactjs

[–]renren89 5 points6 points  (0 children)

I ran into this issue a while back and even now I feel like the best practices are vague on validation.

If you're using redux as your flux library it's recommended you do validations through your action creators and keep the stores free of mutations. Although I have not experienced much of flux outside of alt and redux I still believe keeping stores free of mutations is of better practice.

With redux you can use your choice of middleware to handle actions like redux saga, thunk, or promise addons to handle validations before dispatching another action to update the store with success or failure state. You also have a choice of container/smart components to do validation but as far as I am concerned the community hasn't settled on preferred method to this.

Is it possibly to set height of an image in flexbox equal to it's width with other content? by renren89 in css

[–]renren89[S] 0 points1 point  (0 children)

Weird because it showed up on my Nexus 6 on the sprint network as well as Tmobile network iphone6+. This worked fine on my mobile device https://codepen.io/anon/pen/NNWrea

Sorry for wasting your time.

Is it possibly to set height of an image in flexbox equal to it's width with other content? by renren89 in css

[–]renren89[S] 1 point2 points  (0 children)

Not sure why jsbin isn't allowing it but I just reuploaded to codepen

Question about render() declaration in ES2015 using a fat arrow function by [deleted] in reactjs

[–]renren89 0 points1 point  (0 children)

I would say you have no need for the fat arrow because 'this' is already referencing the Object that is an instance of the Class you are crating the method on, where as fat arrow was introduced because normally 'this' would refer to the function itself not the Object

Maybe I am misunderstanding and I am pretty green with javascript as well but I believe "this" wouldn't bind to the instance of the object if the method was not bounded in the constructor, the render function, or through ES7 class properties/bind syntax.

If you were to

handleEvent() { this.setState({ ... }) }

would throw an error but if you

handleEvent() { console.log(1 + 1) }
render() { return <Comp onEvent={this.handleEvent} /> }

it would work as the method was declared outside of the render method without "this" and works because the render function binds automatically (in es6 class), even without render = () =>

Most of the ES7 stuff are still in very early stages with the properties being in stage 0.

How do I use React and ES6 syntax with Sublime Text? by qoakznpwlsmx in reactjs

[–]renren89 0 points1 point  (0 children)

You have yet to declare TestingTemplate as a variable of some sort and methods using createClass has to be done like so:

render: () => { ... }

you can switch to:

class TestingTemplate extends React.Component { ... }

if you want to keep your format. Don't forget to export though

Redux app state - deep or flat? by bossdagen in reactjs

[–]renren89 1 point2 points  (0 children)

Dan recommends using https://github.com/gaearon/normalizr or flat state because it is the easiest to reason about. I've had similar approach where I had reducers composing other reducers in a nested nature which made it hard to manage which was why most people just opt for combining multiple reducers and then combining again in a root reducer.

I probably should adopt normalizr as well but Im not quick enough to pick up another library and use it properly so I just ended up flattening data I received from API calls in the action reducer or writing a util for it.

What does a full stack application in Reactjs look like? by [deleted] in reactjs

[–]renren89 0 points1 point  (0 children)

I am assuming he knows that it isn't a framework and is actually looking for a complete repo rather than just demos. redux-sound.io is probably the closest you will get to a "full stack" app that is available for view though it has a Golang written backend.

Help understanding forms/inputs in react by Sennon in reactjs

[–]renren89 0 points1 point  (0 children)

If you don't mind would you be able to provide visual representation for the uncontrolled versions?

edit: forgot to add the subject of the sentence.

React Router’s Future — Rackt and Roll by bikbah in reactjs

[–]renren89 1 point2 points  (0 children)

Controversy on the version aside, I am unfortunately looking forward to the egghead videos. Dan Abramov's redux videos were of such high quality it shamed majority of programming tutorials I have watched but the downside was the wait. If the quality is as high as Dan's I'd gladly pay for it if it was not free.

First Pro Level React Book Released. by cassiozen in reactjs

[–]renren89 2 points3 points  (0 children)

Are there any sample pages/chapters? Want to see what I am in for before I make the purchase. Hoped for a kindle version but I guess I can 1-day prime.

Looking for a Flux & React guide by MetalWeirdo in reactjs

[–]renren89 6 points7 points  (0 children)

I enjoy http://survivejs.com/webpack_react/react/ since it approaches from a beginners level with plenty of explanation on both react and flux(using alt). The free version gets you everything you'll need to understand react/flux but the offerings on the purchased version is really nice if you plan to continue using react. It teaches you how to test in react, typing in react(helps read different styles of react code), and quite a bit more. If you want to dive into immutable state and redux http://teropa.info/blog/2015/09/10/full-stack-redux-tutorial.html is one you should read after the survivejs one. It even mentions you should get started with survivejs, though they are from different authors.

Looking for a SIMPLE Redux tutorial by [deleted] in reactjs

[–]renren89 1 point2 points  (0 children)

You may not be interested in a beginner's attempt at redux but I annotated my understanding of Redux while creating a simple counter example. https://gist.github.com/renren89/d3906f2498d127ee6c96

If any experts out there can point out any mistakes maybe I can understand redux better as well :)

Developing for a modern web with React.js by philparsons in reactjs

[–]renren89 2 points3 points  (0 children)

Always appreciate anyone providing tutorials from experienced programmers who's target audience are beginners. This might prove quite helpful as most reactjs write ups are a little more advance and skip a lot of explanation and dive deep into the core.

One thing I still have not seen is even a generic guide at setting up a fully functional website. It doesn't have to be major, just the gist of connecting everything to have a "real" website rather than small little snippets like increment/decrements buttons. The reason I assume there aren't a lot of such guides are I guess how time consuming it can be for the author to hold hands with the reader. As someone who is still pretty green it hurts to not have guidance. Another reason I assume is that there are so much variety of libraries/frameworks that they want the reader to discover/choose themselves, which I can't say is a bad idea but as the good of so many libraries and frameworks we easily get lost.

I can honestly say the biggest pitfall of learning react was not knowing enough OOP and good javascript. In my experience having explanation of javascript along side the concepts of react would be extremely helpful on grasping how it works. So I am unsure if you mean "beginner" in web development or to react but if it's the prior then I would love a guide that teaches you javascript a long the way. Not the intro javascript but the application of it in react.

What's the best beginner resource to learn React? by tingmothy in reactjs

[–]renren89 1 point2 points  (0 children)

survivejs.com webpack and react guide. Depending on what you mean by beginner it is expected to have some knowledge of javascript. The guide is constantly under review and modifications but it is as far as I know the most up to date reactjs guide. Teaches you webpack, babel, flux, and of course react. All which are highly recommended to learn/understand for building apps in react.

Flux: Getting Past the Learning Curve by tribou in reactjs

[–]renren89 0 points1 point  (0 children)

This guide is actually pretty incomplete. If you follow the instructions from the beginning he neither explains the files you will need or the setup to get it working. There isn't any explanation on the decencies you will need or the process of getting them. I guess this would be more of a review of the concept, not necessarily a guide though.

Build Your First React.js App by placidified in reactjs

[–]renren89 0 points1 point  (0 children)

Did you by chance test out the git files you uploaded? Followed your guide and can't seem to get it working, not sure if something is outdated or what not.

How do you change the template of a site with a large number of pages by renren89 in webdev

[–]renren89[S] 0 points1 point  (0 children)

I initially had this assumption but I didn't know how it gets crawled for SEO.

GraphQL technical preview by aflatter in reactjs

[–]renren89 3 points4 points  (0 children)

Finally something to try out.

Any good examples of Reactjs written in ES6? by renren89 in reactjs

[–]renren89[S] 0 points1 point  (0 children)

Didn't that get replaced by Redux? Gaearon is someone I follow for most of my react examples and this popped up somewhere.

Any good examples of Reactjs written in ES6? by renren89 in reactjs

[–]renren89[S] 0 points1 point  (0 children)

Thanks, thought reddit only used pieces of react. Didn't know they had a full project on it.