Skip to content

docs(RenderSystem): add @param em and @returns to flushStaleMeshBuffers JSDoc#407

Merged
ormidales merged 2 commits into
1.1.17from
copilot/patch-add-returns-tag-to-jsdoc
Apr 2, 2026
Merged

docs(RenderSystem): add @param em and @returns to flushStaleMeshBuffers JSDoc#407
ormidales merged 2 commits into
1.1.17from
copilot/patch-add-returns-tag-to-jsdoc

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 2, 2026

flushStaleMeshBuffers was missing @param em and @returns tags in its JSDoc block, leaving documentation generators with incomplete output and inconsistent API docs.

Changes

  • src/core/ecs/systems/RenderSystem.ts — added @param em and @returns void tags to flushStaleMeshBuffers, positioned before the existing @example block:
/**
 * Releases GPU buffers for mesh components that are no longer attached to any
 * active entity. …
 *
 * @param em The entity manager whose active entities are checked.
 * @returns void
 * @example
 */
flushStaleMeshBuffers(em: EntityManager): void {
  • tests/ecs.test.ts — added two JSDoc contract tests (consistent with the repo's readFileSync + substring assertion pattern) asserting that the @param em and @returns tags are present in the JSDoc block immediately preceding the method signature.

… add matching tests

Agent-Logs-Url: https://github.com/ormidales/microgl/sessions/13b57889-c7bf-4004-a3e8-ffc596e587ec

Co-authored-by: ormidales <46538211+ormidales@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix JSDoc for flushStaleMeshBuffers by adding @returns tag docs(RenderSystem): add @param em and @returns to flushStaleMeshBuffers JSDoc Apr 2, 2026
Copilot AI requested a review from ormidales April 2, 2026 12:50
@ormidales ormidales added this to the v1.1.17 milestone Apr 2, 2026
@ormidales ormidales marked this pull request as ready for review April 2, 2026 12:55
Copilot AI review requested due to automatic review settings April 2, 2026 12:55
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates API documentation for RenderSystem.flushStaleMeshBuffers by completing its JSDoc contract and adding tests to ensure the tags remain present.

Changes:

  • Added missing @param em and @returns tags to the flushStaleMeshBuffers JSDoc block.
  • Added contract-style tests that assert the @param em and @returns tags exist in the JSDoc immediately preceding the method signature.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/core/ecs/systems/RenderSystem.ts Completes the flushStaleMeshBuffers JSDoc by adding @param em and @returns tags.
tests/ecs.test.ts Adds contract tests to prevent regression of the new JSDoc tags for flushStaleMeshBuffers.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/core/ecs/systems/RenderSystem.ts
Comment thread tests/ecs.test.ts
@ormidales ormidales merged commit 4e5b1b9 into 1.1.17 Apr 2, 2026
6 checks passed
@ormidales ormidales deleted the copilot/patch-add-returns-tag-to-jsdoc branch April 2, 2026 13:02
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.

[PATCH] RenderSystem.flushStaleMeshBuffers — JSDoc missing @returns tag

3 participants