TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

React created roadblocks in our enterprise app

206 点作者 andreiursan超过 4 年前

55 条评论

iagorodriguez超过 4 年前
The problem is not about react or not react, the problem is how to align big team to create an application. If a big team is going to be working on it you need some strong opinions around it. Do not mess with the package.json. I cant stress this enough. Actually, the most important file in your whole application is the package.json. Almost nobody should be allowed to add additional dependencies because is the main point to generate chaos and problems in the long term.<p>Also, the design system matters a lot. Have a small team working on the UI components to tailor and extend the design system. Dont allow the rest of the teams to extend the ui components with new libraries. Stick with the design system as much as you can. The rest of the teams should minimize the amount of CSS they have to write to components placement.<p>Usually the datagrid is the soul of any enterprise application. Choose it wisely and be sure it covers as much functionality as you can and also that it is customizable on an &quot;easy&quot; way. There is always a team with the need of a datagrid that sorts, groups, filters the data with dynamically adjustable cells and multi header items without pagination. Welcome to hell.<p>Use one pattern: hooks, central store, whatever you want. If at some point you have to change it you have to know which teams are using which one. Dont allow team members of the same team follow different patterns. Code reviews must take care of this.<p>Hope this small tips help one or two teams out there. I have worked on the migration of 5 big enterprise applications from angularjs to react or from legacy desktop application to react or from server pages to react.<p>I made a lot of mistakes that costed a lot of dollars. I have tried to learn from them. Also, dont take me very seriously, I am pretty sure I am about to discover another mistake I have made.
评论 #25876901 未加载
评论 #25877460 未加载
评论 #25875457 未加载
评论 #25876991 未加载
评论 #25877291 未加载
评论 #25876196 未加载
评论 #25875391 未加载
_coveredInBees超过 4 年前
I read the comments here first before reading the blog post, and I was expecting a very different type of (and lacking) blog post based on the combination of dismissive and defensive attitude permeating a lot of the comments here.<p>To be honest, there isn&#x27;t a lot the author is wrong about. Sure, having a .NET team adapting to React is harder but nothing seemed egregious in the way they tackled things. The point about React including so little that you become reliant on a ton of external dependencies that see even more churn than the usual JS framework landscape is a very valid pain point, especially when you are building a very large application for the long-term. Granted, a lot of that criticism holds true for the entire JS scene where the churn is simply ridiculous and you have to cross all your appendages and hope for the best before you try to build a year old project. But React is especially problematic in that regard only because there are so few batteries included (which is great for small&#x2F;mid sized projects, but the opposite if you are looking for stability).<p>Ultimately though, I just shudder to think about writing large, complex, enterprise Apps in the latest and greatest JS&#x2F;front-end frameworks due to the crazy levels of churn in frameworks, libraries and APIs. React now looks completely different from React from 1-2 years ago. Libraries fall in and out of favor. Some keep up with the ever changing API of the parent frameworks, others die off. It&#x27;s like an entire ecosystem that has ADHD and as someone who has built several small to mid-size React and React + Electron apps in the past, that ultimately turned me off the entire endeavor (I&#x27;m an ML Engineer, but I love software engineering and building stuff for fun). I would much rather take &quot;boring&quot;, stable languages and frameworks and spend my time honing skills that actually matter and help me as a software engineer throughout my career, rather than spend a week trying to get webpack figured out, till the next big webpack update when I&#x27;d start over from scratch again.
评论 #25875639 未加载
评论 #25875743 未加载
评论 #25876152 未加载
评论 #25875631 未加载
评论 #25876213 未加载
评论 #25876419 未加载
评论 #25875651 未加载
iamsb超过 4 年前
As a counter point, I was almost fired for not choosing to build a SPA for an internal app which was going to be used by 3-5 people, 5-10 times a month, if that many.<p>I worked at large accounting software provider, and internal billing system used static pricing which was changed once a year. The company wanted to move to a more flexible system where pricing can be setup based on few rules like customer type. For this the ui and backend system needed to be developed. Design I proposed was a single &quot;monolithic&quot; service which did everything including UI and UI was supposed to be a old style mustache templates and some minor jquery. Instead they went with pub-sub systems, 4 different microservices, a react based UI, api which used json-schema, even to send data back to UI. When I left a team of 6-7 people was working full time on this and they were about 20% done.
评论 #25877413 未加载
评论 #25876442 未加载
评论 #25875594 未加载
评论 #25881359 未加载
评论 #25876732 未加载
andrewstuart超过 4 年前
One of the core reasons software projects run into problems is politics - and this article is about politics.<p>What should have happened ideally is that the blog post author would have said to the CTO:<p>- we&#x27;re going with React<p>- you&#x27;ve chosen us to guide you in this<p>- you now need to trust that my advice on standards and approach is correct<p>- you need to get your developers to do it the way I say<p>- if you don&#x27;t, then we will be building a frankenstein React project which is built like a .NET application<p>- the success of the project is at risk<p>And the CTO would have been wise enough to agree and pull his people into line and give the blog post author the authority to demand things be done as he says they should be done.<p>But that&#x27;s politics and hard to do.
评论 #25877525 未加载
评论 #25881410 未加载
评论 #25877100 未加载
评论 #25877050 未加载
hyperpape超过 4 年前
One thing that I realized recently is that if you have a mantra of making &quot;data-driven decisions&quot;, then you have raised the cost of making a decision. What you then need is a tool that minimizes the number of decisions you have to make. Gartner, Rails, Spring, each try to do some of that in their own ways.<p>That&#x27;s where his 3 weeks of decisions about libraries reveals a real mismatch between React and the enterprise way of doing things. React requires a lot of decision making, and enterprises are bad at making decisions.<p>Ultimately, the fault is with the enterprise. Sometimes you don&#x27;t need official data, you just need someone with good taste to make a decision (and if your developers cannot usually &quot;disagree and commit&quot;, that&#x27;s a people problem). Save the data for the big picture stuff.
评论 #25875864 未加载
评论 #25880889 未加载
maxfurman超过 4 年前
This mirrors my own experience with React. The core library itself is fine, and I love the way it bridges functional paradigms without forcing a ton of functional vocabulary on the team, but the ecosystem is a mess. And, because the React core is so minimal, eventually you need to interact with that ecosystem. JS dependency hell is real, and it&#x27;s worse with React than any other framework that I&#x27;ve worked with.
评论 #25875454 未加载
yummybear超过 4 年前
It does sound to my like all of these issues would be the same no matter what library&#x2F;framework you chose. Working “against the grain”, choosing third party libraries, managing coding conventions and dealing with code bloat is common to all technologies. Unless all these points are adressed, you’re unlikely to achieve success with any platform.
评论 #25876242 未加载
hertzrat超过 4 年前
There are a variety of clips of Jonathan blows twitch stream where he talks about web development. He feels that it has gotten so inefficient and complicated that it now takes 20x as long to create something as it needs to. He suggested that it would be faster for most teams to create their tech stacks utterly from scratch. He further argued that once this efficiency problem gets figured out, most web jobs will disappear. This is coming from a guy who is creating his own programming language for his next game though, and who makes his own game engines<p>Eg, here’s one example clip: <a href="https:&#x2F;&#x2F;youtu.be&#x2F;yodWEPgn8NA" rel="nofollow">https:&#x2F;&#x2F;youtu.be&#x2F;yodWEPgn8NA</a>
评论 #25876019 未加载
评论 #25875619 未加载
评论 #25876649 未加载
评论 #25876111 未加载
评论 #25876622 未加载
评论 #25877729 未加载
评论 #25885368 未加载
recursivedoubts超过 4 年前
It&#x27;s funny, react reminds me a lot of J2EE (and other enterprise frameworks) in many ways. A very large and complex framework, with lots of moving parts and additional stuff that needs to be glued in to make it all work.<p>There is a reaction against this happening right now. You can see it in hotwire from 37signals, Alpine.js and my own response to it: <a href="https:&#x2F;&#x2F;htmx.org" rel="nofollow">https:&#x2F;&#x2F;htmx.org</a><p>“Simplicity is prerequisite for reliability”
评论 #25894934 未加载
评论 #25875291 未加载
ourcat超过 4 年前
AngularJS was indeed a bit of a pain when we switched to Angular 2+ and beyond, but it was so worth it.<p>I chose it because of the skillset that our current (small) team has. There&#x27;s no way our &#x27;designer&#x27; (more an HTML&#x2F;CSS guy) could have wrapped his head around JSX, the way it mixes scripts with layout markup.<p>The way Angular separates concerns for us is great. And the components are extremely flexible and reactive and useful for iteration. And lazy-loaded routings? Yes please.<p>And with the Angular CLI and TypeScript typings and using VSCode it&#x27;s an absolute joy to build sites with.
评论 #25875067 未加载
评论 #25876446 未加载
评论 #25880848 未加载
评论 #25875089 未加载
earthboundkid超过 4 年前
Technology problems are usually just human problems behind a mask. In this case, the real problem was a poorly skilled team with bad leadership, and React just exacerbated the problems by giving the team enough rope to hang itself.
评论 #25875123 未加载
评论 #25875066 未加载
评论 #25875713 未加载
评论 #25875197 未加载
评论 #25875267 未加载
评论 #25875440 未加载
评论 #25875453 未加载
评论 #25875105 未加载
评论 #25875207 未加载
samcgraw超过 4 年前
&gt; And I am not even considering the time that each developer spends on learning all those third-party libraries. I never saw two React projects with the same dependencies, project structure, and guidelines. This means the knowledge is not transferable from project to project, as can be the case in Angular or Vue.<p>For a developer just looking to make the thing their design team sent them as quickly as possible, this makes good sense to me. And I get that project&#x2F;file structures can be wildly jarring to an uninitiated dev - I remember looking through a Java repo for the first time :shudders:<p>But! Isn’t there a necessary step of understanding why decisions were made the way they were? In my experience as a front-end eng, even if a previous project involves other-worldly dependencies or FS compared to the one I’m on now, if I understand the trade-offs of the approaches for the previous project, no amount of knowledge is untransferable.
dragonwriter超过 4 年前
&gt; Quick onboarding for new team members, especially for the .NET developers working on the old desktop application.<p>Yeah, unless you have a sufficient base of React (or at least JS) devs to shepherd this, this is obviously going to be a problem for choosing anything that isn&#x27;t .NET, and the further from their existing .NET experience it is, the worse it will be.<p>.NET is a workable web app platform, even for isomorphic apps via Blazor. If immediate onboarding of .NET devs was a key requirement, .NET was the obvious answer.
评论 #25875869 未加载
NiceWayToDoIT超过 4 年前
Here issue is not with React but classic case of poor leadership, architecture and project planing. All issues and road blocks could be avoided just with adhering to a few guidelines.<p>Roadblock #1: I am not even sure why does it matter what is behind the curtain, only important thing are REST contracts, everything else is splitting team front-end &#x2F; back-end. Everyone can have what ever naming convention they want. If project is enterprises it means that has more than 11 people or what is considered as a high number of SCRUM team, so spiting concerns is important and necessary. Everyone does it all (all full-stack devs) just does not work.<p>Roadblock # 2: This is due to experience, and it is up to UI team lead to decide, rest they follow. Sorry, in enterprise projects democracy does not work, maybe in the first few meeting but there you need to draw a line. Regarding dependencies, this is strictly role of one person, everyone else works on &#x27;git pull&#x27; forbid everyone else to fiddle with package.json use lock file strictly and package versions, and you will not have any issues, each machine will have exact copies.<p>Roadblock # 3: This is not a blocker and Hooks have solution for any kind of pattern, it is still possible to use Redux pattern without issue.<p>Roadblock # 4: Machines can get slower, and in my team we had similar issues, but hey you cannot expect to work with 2GB in 2020, not realistic especially with Chrome sucking memory with 34 tabs open. Don&#x27;t forget VS Code is built based on Chromium so basically you have two vampires on you computer. And having virtualized environment is even worse.<p>Roadblock #5: Saga in my case was relief, if you structure correctly Redux Actions and Reducers in neat way, and if you split your concerns, you do not have any issue, in fact it was working as a charm.<p>Again there are multiple approaches how to deal with this, even split project in multiple smaller SPAs if necessary, but at any point not issue with React but more case of PEBMAC :&#x2F;sorry.
serpix超过 4 年前
You just got steamrolled by .NET OOP dinosaurs, React played no part in it.
评论 #25875195 未加载
评论 #25876337 未加载
评论 #25875040 未加载
aeturnum超过 4 年前
I mean, this feels like a classic example of not choosing the best technology for the situation. Picking a more opinionated (or more batteries included) framework likely would have streamlined a lot of the problems he described. That doesn&#x27;t reflect badly on React - certainly there are teams that could have used it to implement a project of this size - but it reflects badly on the author.<p>&gt; I will not encourage using it for enterprise applications.<p>Almost like large-scale projects have different requirements and the tools generally used on large scale projects (like .Net) have adapted to reflect those requirements.
predaking超过 4 年前
So many things here indicating both a strategic problem in the org and some issues with the approach. Context: I&#x27;ve used both React and Angular extensively on a variety of applications, for startups and the most &quot;enterprisey&quot; of entities claiming to be enterprisey (the government) <i>and</i> came from a .NET background prior.<p>First - GRRR. What defined this as an &quot;enterprise&quot; app? Facebook is an enterprise app, dude, with millions of transactions a day. Just because an app is big doesn&#x27;t make it an &quot;enterprise&quot; app.<p>architect was hired from outside to create a proposal for a team that had no one capable of operating in that role (and apparently the CTO as well)<p>&quot;He already has a development partner in India, but they lack experience in building web applications.&quot; - this is a massive red flag<p>architect was sent away to do proposals without anyone talking to the development team to get <i>any</i> buy-in<p>architect got the background of the dev team from the CTO but neither architect or CTO talked to the development team (who would be implementing) prior to doing a proposal<p>&quot;the technical lead ambushes me&quot; - this is the first time the tech lead and the &quot;architect&quot; interacted. There&#x27;s no &quot;ambush&quot; here; it&#x27;s a failing on the CTO+architect&#x27;s part to communicate to the team in advance, and perhaps at least involve the team lead<p>CTO is against angular but his outsourced team is familiar with .NET and Java; why is there even a need for an &quot;outside architect&quot; to make this choice when it&#x27;s only between React and Angular?<p>&quot;the CTO is backing his team, which is normal. He had known me for just two months, while he had been working with his team for many years.&quot; - Why is no one on the CTO&#x27;s team, after many years, capable of investigating and making these decisions? Why did they need to go outside? If the plan was to continue using this outsourced team, why didn&#x27;t anyone invest in their training to be self-sufficient vs a direction from on high? Why was there zero training plan?<p>&quot;And that’s how we end up with three ways of doing things. There is no consistency anymore.&quot; Where is the CTO during all of this?
评论 #25876272 未加载
评论 #25876088 未加载
commandlinefan超过 4 年前
&gt; the new technology’s way of doing things<p>what I find, with virtually every &quot;new technology&quot; that&#x27;s come out in the past 20 years is that the &quot;way of doing things&quot; is not only completely undocumented, but also not agreed on by any two people. I can&#x27;t remember the last time I found technical documentation that even bothered to describe what problem the technology was actually designed to solve in the first place - or was even written by somebody who seemed to understand why that would be important.
devmor超过 4 年前
This had nothing to do with react, and everything to do with you rolling over and accepting what other people wanted to do differently irrespective of your project guidelines.<p>You can&#x27;t expect an application to remain easy to develop when people do not adhere to your development protocols.
bastawhiz超过 4 年前
I think some of the points are valid (.Net folks are not going to have a great time working on a React codebase). I think some of the problems are a result of the decision to use Redux. Redux was very much in vogue for a while, but in every project I&#x27;ve used it for, it really hampers DX when you start to get stuck in on a large project. To do stuff that involves async (read: everything), you need helpers (thunks, saga, etc.) which introduce their own quirks, and require their own tools. Soon, you&#x27;re up to your eyeballs in boilerplate.<p>As for the (build-time) performance concerns, I think there&#x27;s some work here. They have a _big app_. And if you&#x27;re compiling a 220 page app in a single build, it&#x27;s going to get slow. You&#x27;d have the same problem, though, with a native mobile app or a very large C++ app: at some point, you need folks focusing on the infrastructure bits part time. With a relatively small number of changes, they can probably make some big wins: adding build caching for local development, using an NPM proxy (to avoid downloading 600MB of deps over the public internet on every build), looking at alternative hot reload plugins, etc.<p>That&#x27;s not to say React is without problems, but I think it&#x27;s worth considering that _almost any_ technology of the scale of React is going to have drawbacks, especially if you don&#x27;t have someone in-house who has really significant experience making it work well. Companies like Airbnb, Facebook, Uber, etc. all have whole teams (&quot;JS Infra&quot;) dedicated to this stuff, in the same way there are teams like Ruby Infra, etc.
评论 #25876133 未加载
worik超过 4 年前
I have spent my morning pleasantly reading the comments here after reading the article.<p>I am struck that a lot of us here start the comments with &quot;I have been a React developer for [3, 4, 5] years&quot;<p>I think this illustrates the fundamental weakness in the approach of people in the Javascrpt Frameworks world.<p>Billion dollar organisations build software that will cost tens of millions to develop want, or should want, more experience than that.<p>Javascrpit, and &quot;Web 2.0&quot;, generally have been around long enough to meet the requirements, but this churn in frameworks is enough to make anybody with a stake in organisations shake with fear.<p>IMO plain old vanilla JS with a sprinkling of libraries for syntactic sugar (and they can be hand rolled - or use JQuery) is a much better proposition than all of these shiny and new stacks that keep getting deprecated.<p>Web front ends are a huge boon, and the settling of basic JS syntax and implementations makes some very good things possible that were not possible twenty years ago. But the whole industry is being held back by allways wanting &quot;better&quot;, and not accepting &quot;good&quot;.
评论 #25877245 未加载
mpolichette超过 4 年前
I don&#x27;t think React is the problem here. I think communication and leadership is where fault lies.<p>1. Why hire a team of non-webdevs to do webdev. (on 2nd read, it appears they wanted to use the same team from the WPF app... ¯\_(ツ)_&#x2F;¯)<p>2. If you build and treat React components and their APIs as the abstraction layer, then they&#x27;re just components... who cares how they&#x27;re implemented.<p>3. Just because the existing project is big, doesn&#x27;t mean your new one has to be... split it up!<p>4. Redux... the root &quot;technical problem&quot;<p>My hot take is that the authors technical issues probably come from Redux and not React. Using redux as the core of your application is like pouring glue on a lego set. In an ideal world this is great because everything is strong and well defined. In reality, it prevents flexibility and applies hard constraints to the entire system.<p>That one choice of using redux effects the decisions you make in every component. You lose flexibility to encapsulate features and experiments. You&#x27;re forced to bend over backwards to do things in specific ways.<p>Redux is the JS equivalent of the Windows Registry.
评论 #25877299 未加载
评论 #25877340 未加载
评论 #25877544 未加载
atum47超过 4 年前
well, I&#x27;m on the opposite side: I failed two code interviews (before the job I have now) because I did not used React. One comment I will never forget from the feedback I got back from one of the reviewers: JavaScript vanilla is HARD to read. Another one was that I used a &quot;global&quot; css file, instead of having CSS in the same file as the &quot;component&quot;.
评论 #25876015 未加载
akamaka超过 4 年前
I’ve built successful large enterprise apps in React, and would recommend it.<p>Here’s how we avoided some of his pitfalls:<p>* Small team of talented developers who didn’t always agree on libraries and methodology, but worked through disagreements to reach a consensus<p>* Recognizing that libraries would change over a two year project, and being ready for major library migration and refactoring<p>* Writing our own state management tools when needed. Redux is a tiny library. On a two year project, why not create your own custom state management system from scratch, one which makes the .NET people comfortable and has the features that match your project’s needs? It boggles my mind that many devs consider state management libraries to be something sacred, like a compiler, which you would never consider reimplementing yourself on an enterprise project.
评论 #25877923 未加载
flowerlad超过 4 年前
&gt; <i>So I am not afraid of getting into a debate about why those are unusual patterns for React.</i><p>I have seen some developers follow patterns just because they are patterns. Once the community starts doing things one way that&#x27;s it, even if it is a dumb way, the herd mentality causes the dumb way to become established. Redux is one of those dumb ways.<p>&gt; <i>Because 30% of the business logic was inside Redux-Saga, I marked it as a high risk.</i><p>Business logic should be written in POJO. Plain Old JavaScript Objects. Using a library such as Redux is a dumb way, but this is the community-embraced, herd-mentality way.<p>&gt; <i>I will not encourage using it for enterprise applications.</i><p>Use Web Components. Using the flavor-of-the-month JavaScript libs for a large application that must live years or decades is not justifiable.
评论 #25875626 未加载
poulsbohemian超过 4 年前
I&#x27;m not really a React fan, but you could have encountered all of these problems regardless of what you&#x27;d chosen to use. Sounds like the writer had good intentions and worked hard to do the right things, but that there were fundamental misalignments beyond the technology. Could they have planned ahead for those conflicts? Maybe. But, as noted in one of the paragraphs, enterprise type projects have a way of taking on a life of their own even when all parties have the best of intensions - and in many projects, not all parties actually have the best intensions. Heck, I&#x27;ve seen projects get started and deliberately set up to fail as a counterbalance to some other project. Live and learn.
vajrabum超过 4 年前
I&#x27;m think I&#x27;m not able to read this story without paying. Medium seems like they are becoming increasingly a pay to read only service.
评论 #25875201 未加载
renke1超过 4 年前
&gt; “Why are file names dash-case when class names are PascalCase? It should reflect the class name, so from now on, we will name them SomePageComponent.tsx.”<p>That&#x27;s actually a common practice. Files (modules, that is) are usually named after their principal export.
Spivak超过 4 年前
I&#x27;m surprised that you didn&#x27;t pin and vendor your dependencies at the start of the project and declare that any additional dependencies must be compatible with them.<p>Enterprise applications are behemoths that without question will take longer to develop than the current webdev lifecycle and the most important thing for developers writing business logic is structure. Coding against a moving target is a recipe for failure.
titanomachy超过 4 年前
The comments about node dependencies exploding and build times creeping up over time was painfully familiar. I now work at a large company that addresses this with strong library discipline and huge investment in build infrastructure, but when I worked on teams at small- and medium-sized companies we were always plagued by these kind of problems.
satya71超过 4 年前
&gt; Indeed, React is mostly backward-compatible, but the ecosystem around React is not. Developers and third-party libraries will always use the latest features and architecture patterns, while old experiments will be left behind to die. This should not be a problem for small and medium-sized projects because you can adapt much more easily. But for big multi-year projects, these experiments can be a deal-breaker.<p>I really wanted to use React for my current project and it would have sped up development. But I was afraid of this attitude of breaking things that pervades the ecosystem. I&#x27;m using HTML + Alpine.js. It&#x27;s more work, but no breaking changes in libraries so far. I&#x27;m still not sure I made the right call. Only time will tell.
rafaelturk超过 4 年前
This very misleading. Looks like .NET and OOP dinosaurs are the real culprit in your project.
Chyzwar超过 4 年前
In my opinion you need to have a dedicated Tools engineer in teams above 10 people. Most developers are poorly prepared to debug build&#x2F;perf issues. A lot of author issues could be reduced by using right tooling.<p><pre><code> - eslint for style - Webpack Externals&#x2F;Module federation for build times - Dependabot&#x2F;renovate for automatic dependacies - codemon for automated refactors - WSL2 or vagrant VM + docker-compose for local dev </code></pre> You need someone that like tinkering with this stuff instead of doing Jira points game. Give that person autonomy and your team would move faster.
tmpxgdqrcKFuG超过 4 年前
Why <i>not</i> split the frontend and the backend apps into separate applications? That would help with the future proofing since if you wanted to switch to another javascript framework, you could do that.<p>EDIT: forgot an important word
dirtnugget超过 4 年前
It’s sad that Angular still has a bad reputation from AngularJS. Basically all the pain points the author mentions (deciding on router, DI, http client, working in multiple teams, reliable hot-reload, deciding between class or functional components, whether or not to use hooks) are all things in which angular shines. They could have saved a ton of money here by choosing Angular over react. In fact in comparison over the last 5 years, angular has been much more consistent whereas react has become a scattered mess.
chociej超过 4 年前
That was a very interesting read and described a lot of interesting, very valid, and very realistic challenges that I could see myself running into in a similar situation. However I don&#x27;t agree with the conclusion that React shouldn&#x27;t be recommended for enterprise... instead I found myself thinking, gee, there just happen to be other mindsets, skillsets, management styles, and general ways of doing things, and they collided poorly here. Enjoyed reading this but a bit offput by the FUDdy punchline.
fuzzy2超过 4 年前
&gt; Angular would have been a better choice in this case because of similar design patterns.<p>Well sure maybe superficially. There’s classes and then… that’s it. I don’t really see any other part of Angular that would help a (somewhat) experienced (pure) .NET developer in any way. There’s no batteries-included state management either.<p>Technology switches are hard. I don’t think the problem is with .NET specifically but with developers that stopped <i>longing</i>. Longing for new technologies, new algorithms, …
评论 #25878316 未加载
mattgreenrocks超过 4 年前
Unsatisfying read. It wasn&#x27;t React&#x27;s fault. PM was looking for blood. Dumping a bunch of devs who have little experience with the tech onto the project. Little notion of process and conventions for the app. Only reason I&#x27;m commenting is that the three questions posed by the CTO are entirely valid questions and I wished they&#x27;d been answered.
viburnum超过 4 年前
220 pages! That alone makes React a poor choice.
评论 #25875295 未加载
评论 #25879552 未加载
jlbooker超过 4 年前
&gt; He already has a development partner in India, but they lack experience in building web applications.<p>That was never going to go well.<p>&gt; They want to use the .NET guidelines and design patterns in React.<p>Yes, you have .NET developers trying to be web developers. Totally different skill set. That&#x27;s not going to go well, or quickly.
ivanb超过 4 年前
Some of the performance problems on Windows are related to always-on antivirus. Exclude your project directories from antivirus scan and you&#x27;ll see the difference. JetBrains IDEs now even have an auto-suggestion and an option to do it directly from the IDE.
renewiltord超过 4 年前
Is there a Rails for React? I use React+Redux+Typescript and it&#x27;s nice but I always have trouble setting up a new project.<p>Rails is magic in that it&#x27;s all ready. React+Redux+Typescript is great. I just don&#x27;t want to make decisions here. I want to just make a web app. Like how Rails defaults to ActiveRecord and friends, is there something like that for Rails+React+Redux+Typescript?<p>I&#x27;m looking for:<p>* Few decisions for me to make<p>* It&#x27;s relatively popular enough that there is a community around the whole thing<p>It&#x27;s a huge productivity enhancer with Rails to be able to google &quot;Rails do x&quot; and someone has an answer to that. If I had to google &quot;Ruby with X library and Y other library&quot; I think I might commit suicide because the Rust experience is like that: &quot;Use actix-web&quot;. Ah, and how do I use that with this other tokio based library. Oh you can&#x27;t, because you need to make sure the runtimes are compatible.<p>I don&#x27;t want all that.
评论 #25876628 未加载
评论 #25882135 未加载
victorbstan超过 4 年前
Would love see people go back to posting in their own blogs instead of Medium. I get paywalled or app walled. Where I have to either log in or use the native mobile app to read the article. Medium is not a good place to share information.
prewett超过 4 年前
1200 dependencies?! Is this normal in web development? That sounds like a nightmare waiting to happen! I&#x27;m working with a rather large C++ project now, and it only has 40 dependencies, which I already consider pretty large.
评论 #25876837 未加载
joshxyz超过 4 年前
Honestly my primary source of headaches is also the router, the redux, the sagas, the thunks.<p>It&#x27;s always the fuckload of third-party libraries we think we need.
sergiotapia超过 4 年前
I don&#x27;t agree that React is not enterprise ready. The mistake OP made was reaching for Redux for some weird reason. Redux-saga, _thunks_? I guarantee this project used thunks of some kind because some blogger posted about it and it was popular and trendy.<p>Pick boring tech that&#x27;s objectively simple and not an exercise in genius. mobx, today: apollo-client (if you have a graphql api).<p>I&#x27;ve never seen any other project stain a framework as much as Redux has done.<p>Also, he had a ton of organizational issues that have nothing to do with the tech.
评论 #25875080 未加载
评论 #25877971 未加载
评论 #25875804 未加载
mcguire超过 4 年前
Wouldn&#x27;t it have been a better idea to break the giant app into smaller ones with well-defined interfaces?
franklyt超过 4 年前
An unopinionated ecosystem will soon become known a mistake in a similar vein as dynamic typing was.
mrcartmenez超过 4 年前
The problem was not React it was .Net developers. Angular is worse in this regard because the .Net developers feel more confident and charge ahead writing terrible code that is only == to shite rather than === to good. Learn the fucking language first you ahhgsvsvsgsjdhwbdksbdvrievevdjajavsgwgdvshsvevejahahagagagagahgagagagagagagagjgjghgahhagagagahahhahaha
评论 #25879334 未加载
franklyt超过 4 年前
The main problem I’m having here is that I can’t think of any JavaScript framework that has solved this problem.<p>Angular is just too cumbersome, though it gets an honorable mention.<p>Perhaps there is so much churn here because the correct way hasn’t been discovered yet?
评论 #25875673 未加载
valand超过 4 年前
<a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=25874105" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=25874105</a><p>The article pictures conflicts from different programming cultures. There isn&#x27;t any attempt of acculturation mentioned in the article. Acculturation is important to keep everyone in the same page on what&#x27;s the added value of React. You don&#x27;t need people from .NET to get culture conflict, frontend dev that haven&#x27;t got any previous experience with React and the likes, those who operates with jquery and left frontend world, for example, will also introduce culture conflict.<p>In the near beginning, &quot;Where is the dependency injection? What do you mean by ‘There is no need for one?&#x27;&quot;.<p>The React developers seem to also not aware what&#x27;s the significance of dependency injection, therefore the culture acknowledgement goes both way. While the term came from heavy-OOP environment, dependency injection can take a different form.<p>In React&#x27;s world, it can utilize context or types from common module. Dependency injection is crucial in flattening deep components surfaces, which in turn makes them testable. And it&#x27;s not exclusively for the React part. Testable code (with actual tests at STRATEGIC PLACES) makes it easy to increment on, because validating if the added code takes less effort. (Although automated tests at NON STRATEGIC places can make it worse).<p>“Why is the development slowing down?”.<p>I can imagine the author&#x27;s frustration when &quot;They want to use the .NET guidelines and design patterns in React&quot;. I&#x27;ve been in and out some cultures, React, NodeJS, Java, C#, C++, Golang, Android, Game development, Game Engine, Ecommerce, Identity management, Crypto, LL&#x2F;system programming, infra. I can say that without running around and having enough persistence to break and remake cultures while avoiding ineffective compromises, things will not work.<p>CTO losing his temper and blaming for what&#x27;s decided 2 years prior seems like either things have gotten a bit out of control or the environment is a bit toxic. That is if the story is told accurately. Maybe CTO has been constantly reminding the author along the way but only the climax is told because it is peak emotional. Either way, observability and control over the project is lacking. Also the added values of React and other dependencies being included in the project as the main UI library is not communicated well.<p>There are a lot of &quot;should we use [x] lib&quot; going on. The easiest principle is if a module changes a lot, don&#x27;t depend on any lib that locks it in.<p>&quot;Redux-Forms, Formiq, or Final-Form?&quot; This smells, just because without delving deep into the library, Redux-forms seems to tightly couple redux state with, well, forms, which is, in React environment, usually closer to the UI side rather than the core logic side, and you want UI and logic layers to be able to change a lot relative to each other even if they don&#x27;t.<p>On Redux:<p>Redux itself was a weird long-running phenomenon. Its placement relative to other components is a big misunderstanding. It&#x27;s supposed to be a state container that can be either local or global, but the default `connect` API stamps it as a god object permanently in the eyes of the ecosystem. Not to mention countless of medium articles that encourage the pattern.<p>Its &quot;middlewares&quot; such as thunk makes stories hard to write as a single top-to-bottom functions. In one project we identified the risk of misunderstanding as a problem early in the project, therefore redux is removed. We didn&#x27;t even got to touch redux-saga. We had to find a replacement, which is unstated and custom typed event emitter.<p>This buys us code explicitness, loose-coupling, less processes on increments, more accurate types (redux doesn&#x27;t play nice with typescript&#x27;s type system), but we had to pay with writing a lot of types (we are using typescript). It teaches us the concept of message passing ala kafka&#x2F;rabbitMQ, as well as the importance of immutability, which is the core of redux, without redux API bureaucracy.<p>On React hooks:<p>React hooks was a departure to a more (a bit forced) functional programming. Some concept introduced is good as it encourage us to write in automata-based programming style.<p>Automata-based programming <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Automata-based_programming" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Automata-based_programming</a><p>But it has bad API design too. For example `use*` can&#x27;t be written inside `if`. So are custom hooks. We have to be very careful to not place any hooks inside `if`. Writing with hooks needs either: 1.) experienced hooks developers, 2.) linter. You can install&#x2F;write the latter as long as you become the former, which is a paradox. Had it introduced hooks as below things would be a bit better.<p>``` const SomeComponent = makeComponent( ({ context, props }) =&gt; { &#x2F;&#x2F; context supplies useState and useEffect like APIs return ( &lt;ChildComp &#x2F;&gt; ) }, { [stateName]: defaultValue } &#x2F;&#x2F; the default state ) ```<p>The worse part of hooks introduction is that React&#x27;s culture diverge, and so its users. A company can have people with and against hooks.<p>About the title, it should be &quot;Using React the wrong way created roadblocks in our enterprise app&quot;.
erlich超过 4 年前
I feel your pain. It was really too early for React until 2 years or so ago. Since hooks, things have calmed down a bit. I would be interested to hear from people who successfully navigated that past 5 years in JS world. I feel I would have been happier just being forced to use Ember or something until hooks came out. A ridiculous amount of time was spent on tooling, perf optimizations, and huge amounts of code is just going to go into the bin one day.<p>I have this feeling that 2010+ has been this massive story arc and one day we will end up very close to where we started, back to something similar to jquery and vanilla JS because the platform improved. Just like how a React platform feature like context hooks deprecated Redux.<p>For frontend, if Typescript is standardized and shipped with browsers...see ya later beefy compiler toolchains.<p>For backend, Deno.<p>That Typescript with its current popularity is not shipped in browsers within 10 years seems super unlikely.<p>The funny thing with TS is that to get good typing, you start to write everything similar to Java&#x2F;.NET with dependency injection etc. I resisted it for such a long time, but when you realize you want things typed, classes and all those patterns become necessary - see Nest.js&#x2F;TypeORM for an example. It just makes everything cleaner and is easier to standardize patterns.<p>The post seems to have a bit of a &quot;holier than thou&quot; when dealing with naive .NET developers. I think that .NET devs living outside of our JS bubble probably have a lot of interesting criticism to offer. The retort that pops in your mind is &quot;you just don&#x27;t understand...this is how its done&quot;, but if they critiqued any number of the features that have been deprecated in React - they would have been right and us wrong. And even the creator of React said that moving away from classes made it to difficult and would have preferred not to have done it. My point is that JS is a bubble and we shouldn&#x27;t be so sure of ourselves.<p>Also the fact that Apollo is the top API library at the moment, and doing optimistic updates and working with the cache is insanely complicated when ultimately you just want something like ActiveRecord on the client like how we use to do it with Backbone models. Redux and friends is also extremely verbose and complicated for no gain. I miss the simple mental model of Backbone - yeh there were problems, but at the end of the day I just want to write `User.getPosts()` and `User.setPost()` and be done with it. 90% of the time I don&#x27;t actually need GraphQL selective querying and such, its just got such a big momentum and community behind it that I use it. And REST with `react-query` and `swr` is still extremely complicated. Sorry for the rant.<p>So I wonder if anyone has taken the time to predict when all the tools we use today will eventually be deprecated.
moonbug超过 4 年前
web tech really is bollocks, isn&#x27;t it.
评论 #25876098 未加载
cccc4all超过 4 年前
Just reading the initial scope of the requirements. This project was guaranteed to fail, no matter what tech stack was utilized.<p>There&#x27;s no future proofing in Software Development. As soon as an application is deployed to prod, it&#x27;s obsolete. It must be on constant maintenance&#x2F;upgrade schedule. And, the replacement project must be scoped out quickly.
flyinglizard超过 4 年前
First you made a bad choice by using React, then you made a bad choice by publishing on Medium which does not allow anonymous reading.