Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request replaces the JavaScript-based JSDoc configuration file with a JSON-based configuration file (.jsdoc.json) in the packages/google-cloud-tasks directory, updating the source path from build/src to build/esm/src. Additionally, the docs script in package.json is updated to reference the new JSON configuration file. I have no feedback to provide.
shivanee-p
approved these changes
Oct 6, 2026
Contributor
Author
|
Thanks. We'll need to wait for #9523 before merging this one. |
This branch has not been deployed
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
Fixes the failing
npm run docs/pnpm run docsJSDoc generation for@google-cloud/tasks(currently the only generated GAPIC package inpackages/with"type": "module"/esm: true):package.json"docs"script:packages/google-cloud-tasks/package.jsonpreviously referenced.jsdoc.js("docs": "jsdoc -c .jsdoc.js"), which no longer existed after the ESM migration (package.jsonis listed indefault.keepinlibrarian.yaml)..jsdoc.json):jsdoc(cli.js) only usesrequire()whenpath.extname(confPath) === '.js'; for all other extensions (.cjs,.json, etc.), it reads the file as text and runsJSON.parse(stripJsonComments(...)). As a result,.jsdoc.cjswithmodule.exports = { ... }fails withSyntaxError: Unexpected token 'm' ... is not valid JSON, while.jsdoc.jsinside a"type": "module"package returns an empty module namespace fromrequire(). Switching to.jsdoc.json(matchinghandwritten/storage/.jsdoc.json) resolves this cleanly.source.includepath: Dual ESM/CJS packages compile.jssources tobuild/esm/src(rather thanbuild/src). Updatedsource.includeto["build/esm/src", "protos"]so JSDoc locates the compiled ESM sources.A companion PR updates the ESM template and baselines in
core/generator/gapic-generator-typescriptso future generations emit.jsdoc.jsondirectly.Verification
pnpm run compileandpnpm run docsinpackages/google-cloud-tasksand verified./docsis generated cleanly with exit code 0.