Hacker News new | past | comments | ask | show | jobs | submit login

The bigger news is that Lodash is migrating from Node.js to Bun: https://github.com/lodash/lodash/commit/97d4a2fe193a66f5f96d...



Woah.

I was starting to get excited about migrating my packages to Bun, but hesitating because I was afraid of compatibility or whether Bun is really here to stay or not - I have been slightly burnt by "Modern Yarn"; but honestly, seeing lodash make the leap makes me want to consider it more seriously now.


I’m a yarn burn victim as well, and it has made me a lot more apprehensive about fundamental decisions like these. They seem so promising and your research seems to check all/most of the boxes… Then you get Yarn 2/3


Yarn berry has been amazing for me, what problems are you facing with it?


I think if you start from scratch with modern yarn, you’ll generally have an alright time. If you migrate old yard with third party workspaces to modern Yarn with first party workspaces, I think it could be a lot more frustrating. This might be better now due to improved documentation and bug patches. A few years ago it was quite frustrating.


Hmm. If I recall workspace migration was pretty straightforward for me, I thought you were going to bring up PnP, which was not well supported in the beginning. It was frustrating having to change so much of the overall workflow in just the second major version update, and this is exacerbated by their SEO issues, as yarn classic docs still show up before the new docs in Google searches.


Yes, PnP threw a real stick in things. Did you migrate to workspaces while using TypeScript? We had major issues with TS, eslint, and I believe prettier all cooperating with each other and other tooling. It was a nightmare for a week or two. Oh, and React Native was a total dead end for a while. Certain libraries in that ecosystem completely shit the bed with workspaces. Man, it's all coming back. Admittedly, React Native's ecosystem was an equal or greater contributor to that suffering. Even on my team at the time, we resented React Native far more than yarn for all of those struggles. We needed to patch a lot of libraries and write way too many pull requests to repositories that were heavily used yet bizarrely under-maintained and unresponsive.


I stay away from TypeScript where I can, preferring JSDoc, and the PnP fiasco was a great example of why. TypeScript's lack of support for the standard node module resolution algorithm is the reason things don't play well. AFAIK there are still issues there. I also avoid the React ecosystem for similar reasons.

Overall, I was blessed not to have to migrate any work TS/yarn repos but my own personal stack was hell for a while. Really glad things have mostly shaken out because yarn is definitely best in class now and is a joy to use. Too bad we're probably all going to end up on bun anyway.


For me I can’t imagine using anything other than Yarn 3 for Javascript dependency management


I think if you start there it’s potentially great. Going through the early migration from classic to modern was where the burn occurred in my experience.


I was using Yarn 1 before, and it was a nightmare. Slow and painful to package applications with lots of dependencies and to deploy.

So yes I did migrate to Yarn 2+, and it made CI/CD much easier and faster.


What's wrong with yarn 2+ (berry)?


My issue is the substantial shift in the API, major bugs and poor documentation in the initial workspaces implementation, then more subjectively, I didn’t like the PnP solution though it seems to work more reliably now.

I worked on a very large monorepo that was using yarn and the headaches that occurred from migrating to workspaces and newer versions of Yarn were absolutely brutal. In many ways things were better and other package managers technically couldn’t offer the same features, but there’s a reason packages like Lerna/Nx/Turborepo were used to accomplish similar things despite it being possible with yarn. It was extremely cumbersome, didn’t work intuitively with TypeScript, felt like a house of cards at times, etc.

I understand it’s better now, but getting hit by that transition was a burn if I ever saw one.


Update: Welp, isn't really working well on windows yet so I'll have to wait anyway.


Huh, that is big news. Especially considering that despite the v1.0 release recently it has performance problems on Windows.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: