Add an empty option
See original GitHub issueI need to make a directory and I need to always have it empty. It will almost never exist, so I don’t want to run rimraf each time before making the directory. That’s a redundant fs operation.
Instead, could makeDir have an empty option? If empty is true, then an exception is thrown here:
Or alternatively, some option that doesn’t silence the EEXIST exceptions. Like opts.throwOnExists
A third possible solution could be that makeDir returns something that tells us if the directory already existed. Like it could return { alreadyExisted: true }
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
default select option as blank - html - Stack Overflow
So after the user selected an option, the empty option disappears. Save this answer. Show activity on this post.
Read more >Should a blank option always be included in <select> inputs?
As you have suggested, I would recommend in the instance of a required field, that you don't have the "please select" option when...
Read more >Add an empty space option to a dropdown menu in Google ...
Check out my course! https://yagisanatode.teachable.com/p/google-sheets/In this tutorial, you will learn how to create an empty option to a ...
Read more >Why does AngularJS include an empty option in select
After a value is selected, the drop-down gets back to its default state. However, while working with the AngularJS dropdown, it was observed ......
Read more >How do I add an empty first field in a dropdown menu?
I have a dropdown menu that I am populating it with data from my db. I am also using jQuery Chosen: https://harvesthq.github.io/chosen/ The...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Side note: this can be done with
dir
in fs-jetpackI guess I will create a new package for this. This one is not that useful anymore, as NodeJS supports recursive mkdir natively