Skip to content

Conversation

@wenfix
Copy link
Contributor

@wenfix wenfix commented Jan 14, 2026

Summary

This branch adds package configuration linting to the monorepo. It adds publint and @arethetypeswrong/cli as dev dependencies, creates lint:exports, lint:types, and lint:package-config scripts in the root package.json, and adds a pre-commit hook to run lint:package-config. All packages now include attw and publint scripts.

This fixes highlighted issues related to package.json files, but left a few outstanding ones:

Outstanding issues:

  • All packages have warnings about .d.mts files referenced in exports, but those files aren't generated. Fixing this requires build changes to emit separate type declarations for ESM and CJS.
  • @metamask/multichain-ui has warnings about ESM files using .js extensions while "type": "commonjs" is set, causing incorrect interpretation. Fixing this requires renaming Stencil build outputs (e.g., .js to .mjs, .cjs.js to .cjs), which would need post-build scripts or Stencil configuration changes.
  • The attw tool reports "FalseCJS" issues because .d.ts files are used for ESM imports when "type": "commonjs" is set, which also requires generating .d.mts files.

These issues require build system modifications and are deferred for future work.

References

Fixes WAPI-925

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed, highlighting breaking changes as necessary
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants