Open terlar opened 3 years ago
I remember reading up on both npm and yarn when I was developing napalm. I seem to recall that all the innovations that yarn brought had been integrated into npm over time, so I decided to simply support npm-style builds. Also, the yarn.lock format can't be parsed natively (with builtins.X
) by Nix, which means pre-downloading the dependencies can get quite tricky! Does this help?
I see, because it is a YAML file right? I guess it could be possible to write a parser for the yarn.lock file in Nix, but might be some work. It makes sense, but still seems yarn is most popular among the people developing nodejs/typescript.
I guess the dirty way would be to do something like this: https://github.com/serokell/nix-npm-buildpackage/blob/master/default.nix#L222-L230
But I guess that is in the murky Nix practices.
I see, because it is a YAML file right?
I was under the impression that it was a custom format but maybe this changed? I encounter yarn in the wild rarely these days (though I don't work much with javascript), I assumed it was slowly dying...
I have worked on some projects where
yarn.lock
is used and teams seem to be quite attached toyarn
so it seems unlikely that they would switch away from it completely. Does it make sense to supportyarn.lock
as well for source of dependencies?