I fear that by the time I'm good enough at react, another library will come out
Learn React by building a web app
21–30 of 107 posts
Re: Learn React by building a web app
#22One thing completely missing from courses is how to handle animations. Most React apps have no animations whatsoever (including mine, because I have no idea how to implement them), but they're important for usability IMHO.
Class names and CSS transitions have worked just fine in my experience. That said, I'm much more in favor of external stylesheets than coupling styles with components themselves. It seems like the trend with React is to do the opposite.
Perhaps providing hooks to override the behavior, but even not.
Re: Learn React by building a web app
#23One thing completely missing from courses is how to handle animations. Most React apps have no animations whatsoever (including mine, because I have no idea how to implement them), but they're important for usability IMHO.
Hey, sorry to hear that, i thought it was more of a CSS topic then React's and because of that i have not recorded lesson regarding animations. I don't know if it help you, but in most cases i use CSS transitions with classname manipulations and lifecycle methods if needed.
Re: Learn React by building a web app
#24I fear that by the time I'm good enough at react, another library will come out
Probably next big thing will be straight web components or UI libraries like react or angular converting to web components. So everything should be nicely interoperable in the future, it'd just be a matter of how your modeling your data.
Re: Learn React by building a web app
#25Earlier quoted context omitted.
I'm literally working on a lib to solve this right now, specifically to be used with react-router. If you want I can contact you when finished and you can give it a whirl. Implementation will look something like
Transitions are fine, I'm more worried about how to give an indication that a panel has been open or similar. I'll check it out, though! If you have a mailing list feel feel to add me: me@nbrogi.com :-) EDIT: I think your comment below is too deeply nested and it doesn't let me reply. However: I think a mailing list is useful even for personal project. In the event that the project gets traction, it would allow you/m…
This uncovered a new problem for nested animations. The high-level page transition animation occurs even when the url root does not change. So I need to be able to ignore animations on Route components located high in the VirtualDOM, and apply animations (sometimes different animations) on Route components located further down.
Maybe you already know of an elegant solution to solve this problem? If so let me know! In the meantime, I'll keep bang'n on this.
Edit:
Concerning giving an indication that a panel has been opened, I'd just use CSSTransition wrapped around whatever element that is going to be introduced to show that it has been opened. Then define your 'enter' animation in css.
If that seems like overkill, and you can't use did mount to determine if the animation should be applied, then I'd just add a css className to your element to introduce some animation defined in CSS.
Obviously, I may be misunderstanding your use cases here. The above are just knee-jerk thoughts on it.
Re: Learn React by building a web app
#26Earlier quoted context omitted.
Probably next big thing will be straight web components or UI libraries like react or angular converting to web components. So everything should be nicely interoperable in the future, it'd just be a matter of how your modeling your data.
I personally think that it will be React(-like), but in Rust, using Wasm.
Re: Learn React by building a web app
#27I fear that by the time I'm good enough at react, another library will come out
Re: Learn React by building a web app
#28The number one thing I’d like to strengthen is the process of building a react component for publishing on NPM. It’s way different from building something with create-react-app. I need a solution that has zero config, has HMR, the latest JavaScript and automatic deployment for demos on github pages. I have so many components I could publish, but just can’t be bothered to figure this out.
Hey! I have edited create-react-app to build React libraries with it, it has exactly same features as CRA. https://github.com/DimiMikadze/create-react-library
Re: Learn React by building a web app
#29I fear that by the time I'm good enough at react, another library will come out
Eh, React is 5 years old. I've been writing it professionally for 3. I'm not worried. And honestly -- React doesn't have the same pain points jQuery/Backbone/Angular1 did where I couldn't wait to move on after 6 months. We'd have to see an absolutely massive paradigm shift before I'd regret writing my apps in React.
- The core language has gotten a lot better with ES5+ features. Async, fetch promises, etc., are all now built-ins on modern browsers, and have learned lessons from the pain points the initial implementations in libraries like jQuery.
- React itself is only a view layer with minimal concern about the form of your data -- you can use an array of other libraries on top of it to help with shared states, network requests, etc.
Will someone come along and do a view layer better than React? Probably. Will it be as big of a leap as what we've seen over the past few years with ES5/6/7 & React? I don't think so.
Re: Learn React by building a web app
#30I fear that by the time I'm good enough at react, another library will come out