5 ms·
I like your advice, but I think there is a reason for the complaints. An indefensible complexity has become the new normal. And it's what many people are forc
by jonahx 6y ago
I like your advice, but I think there is a reason for the complaints. An indefensible complexity has become the new normal. And it's what many people are forced to suffer through at work. If having a chorus of complaining dissenters on HN threads sways even a small percentage of people to take simpler approaches, it has done some good.
- tkzed49 6y agoWhen people are complaining about this kind of stuff at work, it raises the question of what the alternative is. The person you're replying to describes a great methodology for smaller projects, but in many cases there are great reasons to take on dependencies. Not taking a dependency means you pay in person-hours to reinvent it, and sometimes that cost is much higher than a couple extra seconds of build time. And, once you have a lot of dependencies, ES modules won't save you. People expect web apps to load fast, and code is big. Things like Webpack help make it a lot smaller. My point isn't that this is good, it's that it's not "indefensible". There are very real practical reasons that big companies deal with the debt of dependencies and bundlers.
- runarberg 6y agoMany people (including my self at work) handle webpack configs just fine. I started a vue project at work the other day and it was as simple as: npx @vue/cli@latest create my-project This scaffolded a fully configured project with webpack, babel, typescript, eslint, a custom dev server, etc. I think react developers have a similar tool called create-react-app. I personally (or professionally, since I only use this at work; personally I just have an `index.html` and a python server) just let vue-cli handle the webpack config and forget about it. I guess rust developers use cargo to the same manner. I suspect much of the complain about the complexity of the front-end ecosystem comes from people that either a) don’t do front-end regularly and are trying to build a website for them self but get bad advice for the tools needed, or b) are backend developers at work and think they know better about the front-end then their front-end counterparts. In the case of (a), they simply just need better advice on tooling (and which tools are an overkill), the tone of my original comment was more directed at the other group (b; although the advice I gave was for the former group—whoops).
- dmitriid 6y ago> it was as simple as: This just hides all the complexity behind a yet another layer of abstractions. The moment something breaks due to a minor upgrade, you're screwed.
- lights0123 6y agoAlthough, I do think that Vue handles the webpack config in a great way. I've been using vue-cli to manage my webpack config for years now, and never had a minor upgrade of any dependency break the build. It also provides a nice way to hook into the webpack config, so you can still add your own plugins and loaders without having to opt out of it managing it for you.
- onenite 6y agoIf one is in the majority and is suffering, then there is an opportunity to examine what one is doing, not to mention the environment. After working at small shops managing frontends with 1-2 other people and then moving to frontends managed by larger numbers and divisions, especially in a culture of moving quickly, things can get hairy quite fast. Even so, it helps to make a habit of revisiting things from first principles and to also assume the beginner’s mind, collectively, to work towards more refined, elegant, simpler systems/modules based on lessons of the past. Speaking of “normals”... it used to be normal for most people to be undernourished. Now, the normal is that the majority of people in many developed countries are overfed. And overstimulated. Same with the code we write. Overfed. Overstimulated. The dangers of prosperity and excess! But at least we have the opportunity to focus and sharpen our realities. ... Anyway, back to Webpack. Webpack is great. It is one such system that went through a lot of growing pains and complexities to get used to, not to mentioned subpar documentation in the early days, but it has evolved gracefully and is quite elegant, and has been for a few years now! Read the docs, people! And modern refined tools like Vue CLI, create-react-app, Next.js, and now Vite can take care of most of the “boring” frontend configuration! No one really needs to struggle with Webpack anymore.
- qudat 6y agoDissenters are almost always people who haven't spent enough time in the JS ecosystem to understand why we need the tools we need to be successful. If you want to build a web app, you must target javascript and the browser. There are so many backend programming languages that enables developers to figure out their preferences. I get it, if I didn't have a choice but to build every web API using rails I think I would stop doing web development as well. I learned to embrace the JS ecosystem and all of its quirks a long time ago. I think the ecosystem is first class and better than most other ecosystems I've part of. None of the dissenters ever have good enough arguments to sway me. To each their own, but JS is a fantastic, vibrant ecosystem with exceptional engineers solving problems that are wholly unique to the browser.
- cxr 6y ago> I learned to embrace the JS ecosystem and all of its quirks a long time ago. Stop conflating the NPM ecosystem with JS.
- dmitriid 6y ago> Dissenters are almost always people who haven't spent enough time in the JS ecosystem to understand why we need the tools No. Dissenters are almost always people who clearly understand how overly complex and at the same time extremely brittle frontend toolchains are. Understanding why you need these tools doesn't change the reality of what these tools are and how they work.