AAA
adrian@portfolio:~/projects/comercify

Comercify

live site ↗

Typed, dependency-free e-commerce utilities for TypeScript: prices and taxes, discounts, carts, shipping and catalog. Install it from npm, or copy the source into your project with the CLI and own the code.

## challenge

Every online store reimplements the same small pieces: rounding money without floating point noise, taking VAT out of a gross price, picking the best discount, telling the shopper how far they are from free shipping. The challenge was publishing them as a single package that stays dependency-free and tree-shakeable, ships types that resolve under every TypeScript moduleResolution, and also lets a team copy the source into its own project instead of installing it. Comercify grows by modules, one folder per contributor, so the build, the exports and the CLI had to work for an unknown number of them.

## solution

Wrote each utility as a small typed function with its own unit tests, grouped in a module folder that the package exports as a subpath (comercify/adrian) with ESM and CommonJS builds, declarations for both resolution modes and sideEffects set to false. A CLI copies a whole module into the project, the way shadcn/ui copies components, with options for module, output, listing and force, and it never overwrites a file without --force. CI runs lint, typecheck, format check, tests, build and publint on Node 20, 22 and 24, and publishing checks that the tag matches package.json, runs the tests first and publishes with npm provenance.

## stack

ADRIAN-ALVAREZ PORTFOLIO TERMINAL v3.0

(C) 2026 ADRIAN ALVAREZ. ALL RIGHTS RESERVED.

CPU 6502 @ 2.80MHz ........ OK

RAM 64K ................... OK

LOADING PROFILE ........... OK