Skip to content

issue9/events

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

events Go license codecov PkgGoDev

简单的事件订阅发布系统

e := events.New[string]()

e.Subscribe(sub1)
e.Subscribe(sub2)

e.Publish(true, "触发事件1") // sub1 和 sub2 均会收事事件

安装

go get github.com/issue9/events

版权

本项目采用 MIT 开源授权许可证,完整的授权说明可在 LICENSE 文件中找到。