Documentation
¶
Overview ¶
Package reactions owns the M4 "reactions" plugin. It aggregates reaction counts on the user's issues + issue comments via GraphQL. Upstream also covers discussion comments — that arm lands as a follow-up since GitHub's discussion API surface requires additional scopes and a separate query.
Contracts: specs/004-m4-github-plugins/contracts/plugin-p2-graphql.md §7 Data model: specs/004-m4-github-plugins/data-model.md E-028
Index ¶
Constants ¶
const Name = "reactions"
Name is the canonical plugin slug.
Variables ¶
var Plugin plugins.Plugin = &reactionsPlugin{}
Plugin is the singleton registered with the global plugin registry.
Functions ¶
Types ¶
type Result ¶
type Result struct {
Skipped bool `json:"skipped,omitempty"`
SkippedReason string `json:"-"`
Issues int `json:"issues"`
Comments int `json:"comments"`
Discussions int `json:"discussions"`
Total int `json:"total"`
Days int `json:"days"`
Details map[string]int `json:"details,omitempty"`
}
Result is the JSON payload published under data.Plugins["reactions"].