open-ui icon indicating copy to clipboard operation
open-ui copied to clipboard

[invokers] should we pursue proposing method names to match invoke actions?

Open keithamus opened this issue 2 years ago • 1 comments

One of the original design goals of invokers was to match the names of imperative methods (togglePopover, etc) should we pursue specifying these methods on their respective methods e.g. HTMLDialogElement#toggleModal?

If we consider pursuing this, do we also re-evaluate other action names to align them to existing method names or propose methods to match them:

  • Dialog
    • toggle
    • toggleModal
  • Details
    • open
    • close
    • toggle
  • Video Elements
    • playpause
    • toggleMuted
  • Any Elements
    • toggleFullscreen

keithamus avatar Nov 16 '23 19:11 keithamus

There hasn't been any discussion on this issue for a while, so we're marking it as stale. If you choose to kick off the discussion again, we'll remove the 'stale' label.

github-actions[bot] avatar May 17 '24 00:05 github-actions[bot]

Specific naming requirements (https://github.com/openui/open-ui/issues/969#issuecomment-2251153158) mean that method names will not match their methods.

I think as we define new actions we can consider specifying equivalent methods on a case-per-case basis.

keithamus avatar Jul 25 '24 18:07 keithamus