google / codeworld

Educational computer programming environment using Haskell
http://code.world
Apache License 2.0
1.24k stars 197 forks source link

Guide examples should open a new tab rather than replace the existing code #1501

Open bbarker opened 3 years ago

bbarker commented 3 years ago

I've seen my child make this error a few times, whereby he'll click an example in the guide and it will overwrite what is in the currently opened CodeWorld file. Today he somehow ended up permanently (as far as I can tell) deleting the work he had in an existing file. It seems like it may be more desirable to either create a new file when the user interacts with an example in the guide, or append what is in the example to the currently open file.

cdsmith commented 3 years ago

Good point! I really like this, and it should be easy to do. Even aside from overwriting the existing code, it would be valuable to be able to try out an example without closing the Guide and making students find their way back to it.