Yarn v1.12.1 釋出,Facebook 的 JavaScript 包管理器
Yarn v1.12.1 釋出了,這是一個 Facebook 推出的 JavaScript 包管理器。該版本主要是修復了 bug,但也包括功能改進和新增功能,ofollow,noindex">具體如下 :
-
Ensures the engine check is ran before showing the UI for
upgrade-interactive
#6536 - Orta Therox -
Restores Node v4 support by downgrading
cli-table3
#6535 - Mark Stacey -
Prevents infinite loop when parsing corrupted lockfiles with unterminated strings#4965 - Ryan Hendrickson
-
Environment variables now have tostart with
YARN_
(instead of just contain it) to be considered #6518 - Michael Gmelin -
Fixes the
extensions
option when used byresolveRequest
#6479 - Maël Nison -
Fixes handling of empty string entries for
bin
in package.json #6515 - Ryan Burrows -
Adds support for basic auth for registries with paths, such as artifactory#5322 - Karolis Narkevicius
-
Adds 2FA (Two Factor Authentication) support to publish & alike#6555 - Krzysztof Zbudniewek
-
Fixes how the
files
property is interpreted to bring it in line with npm #6562 - Bertrand Marron -
Fixes Yarn invocations on Darwin when the
yarn
binary was symlinked #6568 - Hidde Boomsma -
Fixes
require.resolve
when used together with thepaths
option #6565 - Maël Nison
Yarn 是 Facebook 推出的 JavaScript 包管理器,旨在提供 npm 之外的另一種選擇方案。Yarn 具有極佳的伸縮性,可以支援成千上萬個直接或間接的包依賴。Yarn 的設計初衷是保證穩定性、彈性和高效能。
那麼 Yarn 和 npm 有什麼不同呢?兩者最大的不同在於安裝包的方式,Yarn 用到了 lockfiles 和確定性演算法。Lockfile 會把安裝的包版本進行鎖定,保證了 node_modules 目錄在不同裝置上的安裝結果是一致的,同時支援並行操作,大大加快安裝程序。此外,Yarn 還宣告同時相容 npm 和 Bower,支援兩個倉庫混合使用,同時支援包的離線安裝(只要你曾經安裝過這個包)。
Yarn 1.0 的釋出時間是 2017 年 9 月,可點此檢視更新內容。
Yarn 1.12.1 原始碼下載https://github.com/yarnpkg/yarn/releases/tag/v1.12.1