Option to set 'Folders closed by default'

See original GitHub issue

When we initialise the gui maybe we can pass ‘defaultClosed:true’ or something like that to set the folder’s default open or close state

i’m migrating a three js project with lots of folders being created in different files and to prevent all the folder from getting opened ,at the end of all the folder creation , I loop/traverse/foldersRecursive through the folders and do close.() on them . works great but not ideal while developing

excellent work btw !

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

3reactions
georgealwayscommented, Jun 30, 2022

Thanks! I could see us adding something like this if enough people want it. Maybe closeFolders: true? Or do you imagine that applying to the root GUI as well?

2reactions
georgealwayscommented, Oct 23, 2022

new GUI({ closeFolders: true }) is definitely planned for the next release.

Until then, anyone can use this snippet for the same result:

const addFolder = GUI.prototype.addFolder;
GUI.prototype.addFolder = function(...args) {
  return addFolder.call(this, ...args).close();
};
Read more comments on GitHub >

github_iconTop Results From Across the Web

How can I change the default expansion/collapsing folder ...
... I can find to alter the default setting for this folder. ... Click the Icon on Desktop to be sure it runs...
Read more >
Starting Outlook with all folders collapsed/expanded
If your default startup folder of Outlook is your Inbox folder, then Outlook will always expand that mailbox to the Inbox folder even...
Read more >
How to set a default Folder View for all folders in Windows ...
First, you can right-click after opening a folder and select the Properties option. Switch to the Customize tab and choose a template from...
Read more >
Change how folders are displayed in the Finder on Mac
Use these settings for any folder that uses the same view: Click Use as Defaults. When you're done, click the Close button or...
Read more >
Changing Folder Options | Managing Files and ...
You can restore all folder options to default Windows settings. On the General tab in the Folder Options dialog box, click or tap...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found