ScrollToTopNotify.swift (447B)
1 // 2 // ScrollToTopNotify.swift 3 // damus 4 // 5 // Created by William Casarin on 2023-07-30. 6 // 7 8 import Foundation 9 10 struct ScrollToTopNotify: Notify { 11 typealias Payload = () 12 var payload: () 13 } 14 15 extension NotifyHandler { 16 static var scroll_to_top: NotifyHandler<ScrollToTopNotify> { 17 .init() 18 } 19 } 20 21 extension Notifications { 22 static var scroll_to_top: Notifications<ScrollToTopNotify> { 23 .init(.init(payload: ())) 24 } 25 }