npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

Iโ€™ve always been into building performant and accessible sites, but lately Iโ€™ve been taking it extremely seriously. So much so that Iโ€™ve been building a tool to help me optimize and monitor the sites that I build to make sure that Iโ€™m making an attempt to offer the best experience to those who visit them. If youโ€™re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, ๐Ÿ‘‹, Iโ€™m Ryan Hefnerย  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If youโ€™re interested in other things Iโ€™m working on, follow me on Twitter or check out the open source projects Iโ€™ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soonโ€“ish.

Open Software & Tools

This site wouldnโ€™t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you ๐Ÿ™

ยฉ 2026 โ€“ย Pkg Stats / Ryan Hefner

@lengkapp/la-build

v0.0.4

Published

๐Ÿš€ **la-build** is a high-performance build tool powered by **esbuild**, **PurgeCSS**, **CSSO**, and **Hono SSG**.

Readme

@lengkapp/la-build

๐Ÿš€ la-build is a high-performance build tool powered by esbuild, PurgeCSS, CSSO, and Hono SSG.

It automatically bundles your JavaScript/TypeScript code, generates static HTML from components/Hono apps, recursively analyzes all imported dependencies for unused CSS rules, minifies all assets, and writes them directly to your build directory.

โœจ Features

  • โšก Lightning Fast: Powered by esbuild for ultra-fast JS/TS bundling.
  • ๐Ÿ—๏ธ Static Site Generation (SSG): Render JSX/TSX components or Hono apps to static HTML output directly.
  • ๐Ÿงน Automatic CSS Purging: Scans all source dependency files found during the JS/TS dependency resolution step to strip unused CSS rules using PurgeCSS.
  • ๐Ÿ“ฆ Asset Minification: Compresses JS, purged CSS (via CSSO), and HTML (via html-minifier-terser).
  • ๐Ÿ› ๏ธ Configurable: Run multiple entry points (.html, .tsx, .jsx, .ts, .js) with flexible inputs and outputs in a single build command.

๐Ÿ“ฆ Installation

Install la-build into your project as a development dependency:

npm install -D @lengkapp/la-build
# or
yarn add -D @lengkapp/la-build
# or
pnpm add -D @lengkapp/la-build

๐Ÿš€ Quick Start

1. Create a Configuration File

Create a config.build.js file in the root directory of your project:

// config.build.js
export default [
  // 1. TSX Component / Hono App -> Static HTML + Purged CSS
  {
    entryPage: 'src/pages/home.tsx',
    htmlOutput: 'public/home.html',
    cssInput: 'src/styles/global.css',
    cssOutput: 'public/global.css',
    minified: true, // Optional, defaults to true
  },
  // 2. TSX / JS App -> Bundled JS + Purged CSS
  {
    entryPage: 'src/index.tsx',
    jsOutput: 'dist/index.js',
    cssInput: 'src/styles/global.css',
    cssOutput: 'public/global.css',
  },
  // 3. Static HTML -> Purged CSS & HTML Minification
  {
    entryPage: 'public/admin.html',
    cssInput: 'src/styles/admin.css',
    cssOutput: 'public/admin.css',
  },
];

2. Add a Script to package.json

Add the build command to your package.json:

{
  "scripts": {
    "build": "la-build --config config.build.js"
  }
}

3. Run the Build

Execute the build using your package manager or npx:

npm run build
# OR directly via npx
npx @lengkapp/la-build --config config.build.js

โš™๏ธ Configuration Options

| Parameter | Type | Required | Description | | --- | --- | --- | --- | | entryPage | string | Yes | Path to the JS/TS file (.tsx, .ts, .jsx, .js) or static .html entry file. | | cssInput | string | Optional | Path to the source CSS file to be purged and minified. | | cssOutput | string | Optional | Destination path for the minified, purged CSS output. | | jsOutput | string | Optional | Destination path for the bundled JS file. | | htmlOutput | string | Optional | File path (.html) or directory path for SSG static HTML generation. | | componentName | string | Optional | Specific named export to render during SSG (defaults to default export or the first exported function). | | minified | boolean | Optional | Enables/disables minification for JS, CSS, and HTML assets simultaneously. Default is true. |

deploy

npm whoami
npm login
npm publish --access public

๐Ÿ“„ License

MIT