What I do
Regenerate the MODULES.md file at the project root so it accurately reflects every module in the package.
Steps
- •Scan entry points — Find all
.tsfiles matchingsrc/*/*.ts(excludingsrc/types/). Each file is a module entry point. - •Read each file — For every entry point, identify all named exports and their types/signatures. Read JSDoc comments to extract descriptions.
- •Regenerate
MODULES.md— Overwrite the file using the exact format below. Modules should be listed in alphabetical order by their import path.
Output format
The file must follow this exact structure:
markdown
# Modules All modules are importable via subpath exports from `@dailydotdev/node-common`. ## <directory>/<filename> **Import:** `@dailydotdev/node-common/<directory>/<filename>` <Brief description of what this module provides, derived from JSDoc or file contents.> | Export | Type | Description | | -------------- | ------------------ | ------------------------------------ | | `<exportName>` | `<type signature>` | <description from JSDoc or inferred> |
Repeat the ## <directory>/<filename> section for each module.
Rules
- •The module heading uses the path relative to
src/without the.tsextension (e.g.,utils/env,logger). - •If the filename is
index, omit it from the heading and import path (e.g.,src/logger/index.tsbecomeslogger, notlogger/index). - •The import path is
@dailydotdev/node-common/<directory>/<filename>(e.g.,@dailydotdev/node-common/utils/env,@dailydotdev/node-common/logger). - •If a module has behavioral notes (e.g., environment-dependent behavior), include a bullet list below the description and above the exports table.
- •Only include files that have at least one export. Skip empty files or files with no exports.
- •Do not include files under
src/types/— those are ambient type declarations, not importable modules. - •Always sort modules alphabetically by import path.
- •Always sort exports alphabetically within each module.
When to use me
Use this skill whenever a new module is added, an existing module's exports change, or a module is removed. This keeps MODULES.md in sync with the source code.