lukehaas / RunJS

RunJS is a JavaScript playground for macOS, Windows and Linux. Write code with instant feedback and access to Node.js and browser APIs.
https://runjs.app
2.05k stars 45 forks source link

[Feature Request] Add layout that has vertical file list on the left and code editor on the right #554

Closed KennanChan closed 6 months ago

KennanChan commented 1 year ago

Currently runjs uses a layout that files are stacked on the top in a tab control

When more files are created, it will be too narrow for these tabs in the top area.

It is good to introduce another layout that has a sidebar to hold these files and user can switch between those layouts.

lukehaas commented 1 year ago

Not quite sure what you mean when you say "files are stacked on the top", you mean the tabs? This is a standard tab layout, if you have too many open, it's best to just close them.

KennanChan commented 1 year ago

Understood.

RunJs for me is more like a demo presenter now. I wrote so many demos in it and the tabs became too narrow to add more. Currently I have to save some of them to local files to make space for the newly created ones and reload them when needed, which is kind of inconvenient.

If there is a config to change to a layout that a scrollable tab container is placed on the left and the tab items are stacked vertically, it would be really helpful.

It probably is my misunderstanding to use RunJs in a vs code way, I'll figure out another workflow to fit my use case. Thanks.

lukehaas commented 1 year ago

I see. Thanks for raising this. It's helpful to hear use cases like this that I hadn't considered. For now, as an alternative to saving files, have you considered creating snippets?

KennanChan commented 1 year ago

Cool!!!! I didn't notice the snippets tool until right now. It fits well to my use case.