shlogg · Early preview
Ramu Narasinga @karthik-m22

Unlocking Unbuild's Secrets: Exploring Hookable And OSS Codebases

Discover Hookable, a package by Unjs for Awaitable Hooks. Learn how to use it in unbuild source code: create hooks, register them & call them to trigger callbacks.

For this week, I have been reading unbuild source code and found few packages that I have never seen before or used. I wanted to share some interesting packages that are used in these OSS projects so we can learn a thing or two ;)
The following are discussed in this article:

What is hookable?
Hookable’s usage in unbuild

  
  
  What is hookable?

Hookable is a package built by authors at Unjs. Unjs provides JS tools, libraries and has about 63 npm packages and 421m downloads per month. Sheesh, that’s a lot.

Hookable repository has this description “Awaitable Hooks”.
This package is straight...