Open Collective
Open Collective
Refactor: improve perf by 2.5x with reduced memory and bundle size
Published on October 26, 2019 by Jun Yang

By removing await/async keywords for internal function calls, we removed redundent async/sync implementations (see: thus reduced bundle size, and improved performance (both ops/sec and mem used) considerably. In summary, on MacBook 11,1 (2.4 GHz Core i5, 8G RAM) the improvements are:

  1. ops/sec for typical use cases improved by x2.5 (see above)
  2. memory usage reduced by 2/2 (see above)
  3. size of liquidjs.min.js reduced by 14% (50k -> 43k)

See for details.