Yarn version 2
Christoffer Niska
Why a version 2?
Legacy architecture ๐ข
Initial stack inherit too much from NPM, undocumented quirks, confusing configuration
Easier contributions ๐จ๐ปโ๐ป
Written in TypeScript, scoped features, lower risk of unwanted interractions
New features
Offline mirror ๐ฎ
No network connection required
which means more reliable builds
Plug'n'Play ๐
Generated .pnp.js file
(similar to autoload.php)ย
Improved workspaces ๐
ย
Decouple monoliths into subprojects while still allowing for a "mono-repository"
Improved logging ๐
Message codes and colors to
emphasize
importantance
Yarn DLX โ๏ธ
NPX for Yarn
Install remote packages globally and run them locally
without updating package.json
Interactive mode ๐น
Select between versions, confirm actions for each workspace separately, etc.
Yarn UP โ๏ธ
Upgrade packages across workspaces
Constraints ๐
Linting for package.json
with auto-fixable rules
Zero-installs ๐
Commit node_modules to run yarn install only once
Recap ๐ก
Offline mirror
Improved workspaces
Improved logging
Yarn DLX & Yarn UP
Constraints
Zero-installs
Try it out ๐งช
bit.ly/docker-yarn-berry
Read more ๐
yarnpkg.github.io/berry
Thank you ๐๐ป
Made with Slides.com