Company
Date Published
Author
Swaraj Cheguri
Word count
1590
Language
English
Hacker News points
None

Summary

Harness's adoption of a micro-frontends architecture significantly enhanced its application performance, allowing for independent development, deployment, and efficient resource sharing, akin to microservices for the backend. By transitioning from a monolithic web application to distributed individual applications, Harness achieved improved initial load times, independent module deployments, and reduced cognitive load on developers. The company explored various micro-frontends solutions, including Webpack Module Federation, Import Module As an App, Managed Wrapper, and iframes, each with its own pros and cons related to bundling, dependency sharing, data/resource sharing, and security concerns. Ultimately, Harness opted for a solution that utilized Webpack Module Federation coupled with a wrapper to facilitate two-way data sharing and independent service operation of child modules, enabling seamless integration and flexibility without reliance on a single third-party library. This approach allowed for minimal changes to the existing parent application and fostered an environment conducive to experimentation while supporting open-source contributions.