Tagged articles
1 articles
Page 1 of 1
Qunar Tech Salon
Qunar Tech Salon
Jan 10, 2020 · Frontend Development

Building a TypeScript Utility Library: setDefaults, getProperty, Testing and Multi‑Format Packaging

This article explains how to design and implement a TypeScript utility package with complex type declarations for functions like setDefaults and getProperty, demonstrates unit testing using ts‑mocha and chai, and details the compilation and packaging process for CommonJS, ES modules, type declarations, and UMD bundles using Rollup.

RollupTypeScriptbuild tools
0 likes · 14 min read
Building a TypeScript Utility Library: setDefaults, getProperty, Testing and Multi‑Format Packaging