HeinrichApfelmus / threepenny-gui

GUI framework that uses the web browser as a display.
https://heinrichapfelmus.github.io/threepenny-gui/
Other
437 stars 77 forks source link

Use backtick syntax for `on` in haddocks? #222

Open ggreif opened 5 years ago

ggreif commented 5 years ago

In this line one could advertise a cuter syntax for on:

https://github.com/HeinrichApfelmus/threepenny-gui/blob/f5413b36c95f1abeaca974d7b890b75a738ce554/src/Graphics/UI/Threepenny/Core.hs#L240

namely

-- > click `on` element $ \_ -> ...
bradrn commented 5 years ago

I've been doing a bit of GTK programming recently; in the gtk3 library they do this but the type of on is flipped to get an even more evocative syntax:

canvas `on` buttonPressEvent  $ canvasMouseHandler