Skip to content

refactor: migrate to @jmlweb/tooling packages#10

Merged
jmlweb merged 2 commits intomainfrom
hal/migrate-to-jmlweb-tooling
Jan 27, 2026
Merged

refactor: migrate to @jmlweb/tooling packages#10
jmlweb merged 2 commits intomainfrom
hal/migrate-to-jmlweb-tooling

Conversation

@jmlweb
Copy link
Copy Markdown
Owner

@jmlweb jmlweb commented Jan 27, 2026

Summary

Migrates mochila to use the shared @jmlweb/tooling packages for consistent configuration across projects.

Changes

New Dependencies

  • @jmlweb/eslint-config-base (replaces custom ESLint config)
  • @jmlweb/prettier-config-base (replaces .prettierrc.json)
  • @jmlweb/tsconfig-base (extends base tsconfig)
  • @jmlweb/commitlint-config (replaces custom commitlint config)

Removed

  • .prettierrc.json (now uses package.json "prettier" field)
  • Several redundant ESLint plugins (now provided by base config)

Code Fixes

  • Applied auto-fixes from stricter linting rules (import types, array types, etc.)
  • Fixed for loop → for-of in makeIsDeepEqual.ts
  • Fixed ||?? in lruCache.ts (nullish coalescing)

Rule Overrides

Added project-specific overrides for utility library patterns:

  • Disabled no-unsafe-* rules (needed for throttle/debounce/pipe)
  • Disabled no-empty-function (noop is intentionally empty)
  • Disabled strict rules in test files

Verification

  • pnpm lint passes (1 warning)
  • ✅ All 561 tests pass
  • ✅ Build works

Note

Migrates repo to shared @jmlweb tooling and updates code to satisfy stricter lint/TS rules while keeping behavior unchanged.

  • Replace custom configs with shared ones: @jmlweb/eslint-config-base, @jmlweb/prettier-config-base (via package.json), @jmlweb/tsconfig-base, and @jmlweb/commitlint-config; remove .prettierrc.json and old commitlint rules
  • Revamp eslint.config.mjs: extend base config, add tsdoc, and introduce targeted rule relaxations plus test-file overrides
  • Update package.json devDeps/scripts; regenerate pnpm-lock.yaml
  • Widespread type/lint fixes across src/: switch to import type, prefer readonly ...[] over ReadonlyArray, refine generics/utility types, and minor refactors (e.g., for...of in makeIsDeepEqual, nullish coalescing in lruCache, small readability tweaks in debounce, lastIndexOf)
  • Tests adjusted for new typing patterns (e.g., type aliases, explicit readonly arrays)

Written by Cursor Bugbot for commit 6edff38. This will update automatically on new commits. Configure here.

- Replace custom ESLint config with @jmlweb/eslint-config-base
- Replace custom Prettier config with @jmlweb/prettier-config-base
- Replace custom tsconfig with @jmlweb/tsconfig-base
- Replace custom commitlint config with @jmlweb/commitlint-config
- Apply auto-fixes from new stricter linting rules
- Add project-specific rule overrides for utility library patterns
- Fix for-of loop in makeIsDeepEqual
- Fix nullish coalescing in lruCache

All 561 tests pass.
@jmlweb jmlweb merged commit c8ce5b8 into main Jan 27, 2026
3 checks passed
@github-actions
Copy link
Copy Markdown

🎉 This issue has been resolved in version 1.11.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant