4 ms·
> To me it seems even more ridiculous that react is the silver bullet for frontend development. For me (and other Clojurescript developers) React is one of the
by hacker_9 9y ago
> To me it seems even more ridiculous that react is the silver bullet for frontend development.
For me (and other Clojurescript developers) React is one of the best ways to do front end development. Simply because of it's virtual DOM concept, which allows us to hot reload parts of the page as we write new code. Just save the file and the page updates. It's incredibly productive, and a development experience I've not seen replicated elsewhere.
- tigershark 9y agoVirtual dom has nothing to do with hot reload. Ages ago (more than 20 years ago) you could do the same while writing HTML and refreshing the browser. And if you used WYSIWYG editors it was even mostly unnecessary.
- hacker_9 9y agoRefreshing the page is what you currently have to do with a typical javascript setup, with the main problem being that you lose all your state on the page. For example any form fields you've filled out. With bigger Web apps this can be quite a slow way to develop. WYSIWYG editors are built very specifically to convert to and from from a particular markup to html, they can't process anything outside of that. Clojurescript and React allows me to make changes to part of the DOM and only that part of the page updates, maintaining state on the rest of the page. This is made possible because of React's virtual DOM which can run a diff algorithm and only push through the parts that have changed to the actual DOM.
- danneu 9y agoHot reload means something different than refreshing the page, automatically or manually. If the state of art of your development cycle is refreshing the browser, check out hot reload.
- JustSomeNobody 9y agoIs it the best for your product or your customers. In your case it may very well be. However, you CANNOT[0] make tech stack decisions solely on how easy it is for YOU. [0] Should not.
- hacker_9 9y agoClojurescript compiles down to regular Javascript, and React is used by Facebook which is in the top 3 most visited sites in the world. So what's your point?
- goatlover 9y agoThat most developers won't be building a top 3 most visited site in the world. FB's needs are not necessarily everyone else's needs. React may or may not be a good choice for any given project.
- JustSomeNobody 9y agoI am pretty sure I made my point clear. What is good for a developer isn't always good for the customer.