Multiple files in Web IDE

Posted on
  • I have a quick prototype of this at: https://gfwilliams.github.io/EspruinoWeb­IDE/

    You can now have multiple tabs. For each file you open you get a new tab - and for each tab, the way it's saved is remembered (as well as - finally - the filename!).

    Right now it:

    • doesn't understand about blockly as a type of Tab (the graphical language)
    • re-uses the same editor, so Undo isn't remembered if you flip between tabs
    • doesn't have a 'new tab' button

    What do you think about this? Is it useful? Would it help? Anything glaring that's wrong with the way it works?

  • Without having tested it yet (looking forward to it):

    and for each tab, the way it's saved is remembered (as well as - finally - the filename!).

    This indeed sounds useful to me! Real quality of life improvement 😍

  • How do I load into new tab? Open loads into same tab, I never see more than one. However when I close the tab I get it renamed to Untitled.js and the initial default LED blinking example shows.

    I also tried to drag and drop two files there, only one is shown.

    This is Chrome on Windows.

  • That's a good question! I was sure that worked, but it seems not - I'll look into it

  • Ok, just fixed. There's now a '+' to add a new tab as well.

    I'm not super happy about the current arrangement (as it's effectively bodged on top of what was there already) but I guess it's a start

  • Much better, good start indeed, thank you :-)

    save button pops up a dialog and does not remember folder it was opened from - not sure if anything can be done about it (or even don't ask and just save/overwrite)

    The upload settings are kept per tab so I can have multiple tabs and upload to different storage files, that's neat (even if file is also evaluated instead of just uploading it).

    So now some project file that has a list of files and settings per file saved :-)

  • The save button could allow you to just save over the file on most browsers I think. I just wasn't entirely sure how to choose between "save"/"save as" without adding another button... A little down-arrow as is done for the "open" one?

    Another thing to note is the 'watch' functionality is currently global - so once you turn it on, all files that you opened that session are watched for changes. It's probably not ideal but given the percentage of folks that use watch it's probably ok.

  • edit: sorry - it still needs some work by the look of it!

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Multiple files in Web IDE

Posted by Avatar for Gordon @Gordon

Actions