noprompt / ankha

A data inspection component for Om
Eclipse Public License 1.0
132 stars 12 forks source link

Generalized editor #5

Closed sgrove closed 10 years ago

sgrove commented 10 years ago

Just a thought, but I think it's doable.

  1. Instantiate Ankha with a go channel to listen on.
  2. Double-click to edit a field. Cancel on esc, save on enter.
  3. On save, send a message on the channel with the path in the tree that's compatible with assoc-in, the old value and the new value (ideally coerced into the right type based on the old value type).

Then I can listen on the channel and edit different pieces of the app-state (especially with my draggable window and jump-to-tree-path keybindings) instantly.

sgrove commented 10 years ago

It'd also work to have a callback-based interface if you didn't want to bring core.async into the mix.

noprompt commented 10 years ago

I like it! @swannodette had suggested it would be cool to make it editable. My hands are tied at the moment but would definitely receive any patches/improvements with an open mind.

noprompt commented 10 years ago

Closing this thanks to #8. We'll continue to work on it though. You've made some great suggestions!