mkdist
mkdist copied to clipboard
Maybe provide options to define custom esbuild options?
Hello, I want to use unbuild with mkdist builder to bundle my vue component library and publish them to npm. When using it in my vite project, it seems like vite will not do transform code inside node_modules and, however, my code are required to run in a web browser with chormium 70 and some syntaxs like optional chain may not be supported. I found that using unbuild with rollup builder supports custom rollupOptions and thus can specify custom esbuild options while mkdist does not support custom esbuild options. Maybe mkdist can provide options to define custom esbuild options? Thanks a lot!
Inside: https://github.com/unjs/mkdist/blob/main/src/loaders/js.ts#L33
same issue +1
Yes, I need pass the keep-names
option to esbuild too.
make a pr to support: #144
Hi. This will be possible in next release via esbuild
option