fix: add JSDoc documentation for JSR API docs#177
Merged
jaypatrick merged 2 commits intomasterfrom Jan 15, 2026
Merged
Conversation
Fix JSR API documentation which was showing empty/broken links due to deno doc --lint validation errors. The lint was failing because: 1. @inheritdoc tag is not recognized by deno doc --lint 2. Exported symbols were missing JSDoc comments 3. Type properties needed explicit type annotations Changes: - Replace all @inheritdoc with full JSDoc comments - Add JSDoc to all exported class constructors, methods, and properties - Add explicit type annotations (e.g., `public readonly type: TransformationType`) - Add JSDoc to interface properties Files modified (47 files): - Diagnostics: DiagnosticsCollector.ts - Formatters: OutputFormatter.ts - Transformations: 14 transformation files - Compilers: SourceCompiler.ts, FilterCompiler.ts, IncrementalCompiler.ts, HeaderGenerator.ts - Platform: WorkerCompiler.ts, PlatformDownloader.ts, HttpFetcher.ts, etc. - Services: FilterService.ts, TransformationRegistry.ts - Utils: EventEmitter.ts, ErrorUtils.ts, Benchmark.ts, StringUtils.ts - Plugins: PluginSystem.ts - Diff: DiffReport.ts - Downloader: FilterDownloader.ts Results: - deno doc --lint: 0 errors (down from 188) - deno publish --dry-run: Success - All 832 tests passing 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
adblock-compiler | 62e2f74 | Jan 15 2026, 08:11 AM |
|
Version bumped: |
There was a problem hiding this comment.
Pull request overview
This PR fixes JSR API documentation by adding comprehensive JSDoc comments to all exported symbols. The change addresses empty/broken API documentation links on the JSR package page, which was caused by deno doc --lint validation failures (188 errors, now down to 0).
Changes:
- Added JSDoc documentation to 47 files covering transformations, compilers, formatters, diagnostics, utilities, and platform abstractions
- Replaced non-standard
@inheritdoctags with explicit JSDoc in NoOpDiagnosticsCollector - Added explicit type annotations to transformation classes (e.g.,
public readonly type: TransformationType) - Version bumped from 0.8.4 to 0.8.5 across all configuration files
- Alphabetized imports and exports in workflow files (formatting cleanup)
Reviewed changes
Copilot reviewed 54 out of 54 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/version.ts | Version bump to 0.8.5 |
| src/types/index.ts | Added JSDoc to interface properties |
| src/transformations/*.ts | Added JSDoc and explicit type annotations to 14 transformation classes |
| src/utils/*.ts | Added JSDoc to StringUtils, EventEmitter, ErrorUtils, Benchmark |
| src/diagnostics/DiagnosticsCollector.ts | Replaced @inheritdoc with explicit JSDoc in NoOpDiagnosticsCollector |
| src/formatters/OutputFormatter.ts | Added JSDoc to BaseFormatter and 6 formatter subclasses; exported BaseFormatter |
| src/compiler/*.ts | Added constructor JSDoc to SourceCompiler, IncrementalCompiler, HeaderGenerator |
| src/platform/*.ts | Added JSDoc to WorkerCompiler, PlatformDownloader, HttpFetcher, etc. |
| src/services/FilterService.ts | Added constructor JSDoc |
| src/plugins/PluginSystem.ts | Added JSDoc to PluginRegistry, PluginTransformationWrapper |
| src/diff/DiffReport.ts | Added constructor JSDoc to DiffGenerator |
| src/downloader/FilterDownloader.ts | Added constructor JSDoc |
| src/index.ts | Added BaseFormatter, BaseError, BenchmarkResult, CompilationMetrics, AnyDiagnosticEvent to exports |
| worker/workflows/*.ts | Alphabetized imports; improved string concatenation formatting |
| package.json, deno.json, wrangler.toml | Version bump to 0.8.5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
deno doc --lintvalidation (0 errors, down from 188)Problem
The JSR package page was showing API documentation links that led to nothing. This was caused by
deno doc --lintfailing to validate the documentation, which prevented JSR from generating proper API docs.Root Causes
@inheritdocnot recognized: Deno doc --lint doesn't recognize the@inheritdocJSDoc tagpublic readonly type = TransformationType.Xneeded explicit typesChanges
Modified 47 files to add proper JSDoc documentation:
@inheritdocwith full JSDoc in NoOpDiagnosticsCollector@inheritdocin 6 formatter subclassesTest plan
deno doc --lint src/index.tspasses with 0 errorsdeno publish --dry-run --allow-dirtysucceedsdeno fmt && deno lint && deno checkpass🤖 Generated with Claude Code