ES6 - is there an elegant way to import all named exports but not the default export?
There is no separation between "named" and "default" exports. The default export is a named export, it just happens to have the name default
which is special-cased for ease of use by certain syntax.
The only way to import all of the exported keys is with
import * as foo from "foo";
and that will include the named export default
if there is one. If you wish to exclude it from your checks, it would be up to you do handle that in your own logic, as you have done with your omit()
example.