Janne Aukia 2021-05-10 10:37:59 I’m thinking if it would make sense and be feasible to create a “two-way” editor, where the ground truth would be in code, but you could edit the elements visually, too.
Any examples of:
- Two-way editors, where you could edit the same data in both visual (think Sketch, Blockly, nodes, etc) and code format (JS, Python, custom markup)? Ideally something, where formatting would be preserved when moving between these two domains.
- Papers related to “two-way” transformations, either from a parser point-of-view or on some higher abstraction level (strategies in general, UI:s, etc)?
Janne Aukia 2021-05-10 11:46:20 Thanks! I realized I tried that back in 2018 but had already forgotten about it.
Kevin Greer 2021-05-10 15:43:46 MVC is just two-way data-binding between your models (your data) and your views. Just represent your code as models and then have multiple views, some of which are textual, and some of which are graphical. That's what I do with FOAM (http://foamdev.com). Just treat code as data, and the MVC it.
William Taysom 2021-05-11 00:59:52 I always find the complication is what to do with intermediate ill-formed states.
Jack Rusher 2021-05-11 16:08:39 A bunch of projectional editors have tried to give more than one view on some underlying representation. If you google around you'll find many dead but interesting projects in this space 🙂