Babel 7.2.0 釋出,JavaScript 編譯器
Babel 7.2.0 已釋出,Babel 是用於編寫下一代 JavaScript 的編譯器。此版本包含對私有例項方法的支援以及一些圍繞 Flow 和 TypeScript 類的 bug 修復。
更新亮點
Private Instance Methods ( ofollow,noindex" target="_blank">#8654 )
class Person { #age = 19; #increaseAge() { this.#age++; } birthday() { this.#increaseAge(); alert("Happy Birthday!"); } }
"Smart" Pipeline Operator Parsing ( #8289 )
// "Smart" const result = 2 |> double |> 3 + # |> toStringBase(2, #); // "111" // "Simple" const result = 2 |> double |> (x => 3 + x) |> (x => toStringBase(2, x));
Plugin Names ( #8769 )
發行說明: