Skip to content

Commit

Permalink
add runWidgetT
Browse files Browse the repository at this point in the history
  • Loading branch information
ners committed Apr 6, 2024
1 parent c406ec4 commit 58cb97a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/System/Terminal/Widgets/Common.hs
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,6 @@ runWidget = go Nothing
Right e -> do
let new = handleEvent e current
go (Just current) new

runWidgetT :: forall m w. (MonadIO m, Widget w) => w -> m w
runWidgetT = liftIO . withTerminal . runTerminalT . runWidget

0 comments on commit 58cb97a

Please sign in to comment.