by Ambolia · 4y ago · 0 comments
While on Frontend from the beginning, specially i you are working with a team, you will have to make a lot of small decisions that can cause all kinds of trouble down the line:
- How you build the project, javascript transpilers and all that mess.
- Decide a CSS framework, or not use a framework and then decide on an internal style guide.
- Decide on a component library.
- Decide on how to handle state.
Or you can skip those above and use pure HTML+CSS+Javascript, but those usually end up as very spaguettified and idiosyncratic projects, I rarely see anyone even considering it unless it's a personal project. And for a good reason, the structure provided by component and state handling libraries reduces a lot of the inherent chaos that is structuring frontend web project. But each of those also comes with its own bag of new problems, and complexity that requires the developers to handle a lot of disparate information in their heads while working on a project.
I have yet to work on a React + Tailwind codebase in the wild where the margin/padding metrics aren't hardcoded and repeated across tens of different components. We've traded the elegance of well-written SCSS for improved developer ergonomics and faster build times because webpack is so slow at compiling stylesheet changes.
If you want to practise proper DRY for spacing, typography, etc. in a React app, you'll just end up nesting tons of components that ultimately result in needless complexity.
This is absolutely not my experience. Every company I've worked at has had some long running back end tech debt, trying to swap out old tech.
Every problem you listed for the FE has a BE analog. Is it just that there are a lot of choices for FE tech? IMO that's a strength and not a weakness. There's also a clear leader in the tech for each part of the stack to choose to get something running quickly.
> Or you can skip those above and use pure HTML+CSS+Javascript, but those usually end up as very spaguettified and idiosyncratic projects, I rarely see anyone even considering it unless it's a personal project.
This is like saying you're seeing BE devs consider writing all their DB queries in raw SQL in a production system rather than use an ORM. Sure, it's done sometimes but most of the time it makes sense to use an abstraction layer.
Again, it's mostly whether or not engineers have the time to plan ahead and also update old code.