Skip to content

Add RoosterJS-specific Copilot code review guidelines - #3511

Merged
Julia Roldi (juliaroldi) merged 1 commit into
masterfrom
u/juliaroldi/guidelines-reviewer
Dec 4, 2026
Merged

Julia Roldi (juliaroldi) merged 1 commit into
masterfrom
u/juliaroldi/guidelines-reviewer

Conversation

@juliaroldi

Copy link
Copy Markdown
Contributor

Summary

Add .github/copilot-instructions.md to guide Copilot code reviews toward actionable, evidence-based findings. Define review priorities and RoosterJS-specific checks for Content Model edits, plugin events, package boundaries, type safety, and meaningful test coverage.

How to test

  1. Review .github/copilot-instructions.md for clear review priorities, repository-specific guidance, and focused reporting expectations.
  2. No runtime behavior changes; tests were not run for this documentation-only change. The standard runtime validation command is yarn test:fast.

@github-actions

github-actions Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
PR Preview Action v1.8.2
Preview removed because the pull request was closed.
2026-12-04 22:01 UTC

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The listener guidance is too broad because attachDomEvent cannot replace document-level listeners needed for selection changes and drag releases outside the editor.

1 open issue

Review effort: Balanced


- Check whether a DOM event listener duplicates an event already exposed through `PluginEvent`. Handle covered events through `onPluginEvent` instead.
- Look for calls to `onPluginEvent` from within `onPluginEvent`, including indirect calls that cause recursive event handling.
- Do not attach event listeners directly to `document`. Use `attachDomEvent` for DOM events not covered by `PluginEvent`, and clean up the returned disposer.
@juliaroldi
Julia Roldi (juliaroldi) merged commit f0a8ac8 into master Dec 4, 2026
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants