We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why plugins from Bun.build api not used in bun build --compile? I think it would be useful and convenient.
Bun.build
bun build --compile
For example, we can add binary format or compile property in Bun.build or add new Bun.compile API with esbuild/Bun compability plugins
binary
compile
Bun.compile
Bun.build({ entrypoints: ["example/index.ts"], outdir: "out", format: "binary", // or compile: true, plugins: [ autoload({ pattern: "**/*.{ts,tsx,js,jsx,mjs,cjs}", directory: "./example/routes", }), ], });
Compile already bundled code (An inconvenient unnecessary step)
await Bun.build({ entrypoints: ["index.ts"], outdir: "out", plugins: [ autoload({ directory: "./routes", }), ], }).then(console.log); await Bun.$`bun build --compile out/index.js`;
The text was updated successfully, but these errors were encountered:
i'm surprised it hasn't been implemented before
Sorry, something went wrong.
OMG this is surprising for me too
Not only compile mode, but also normal build command doesn't load plugin
compile: boolean | "${platform}-${arch}"
Successfully merging a pull request may close this issue.
What is the problem this feature would solve?
Why plugins from
Bun.build
api not used inbun build --compile
? I think it would be useful and convenient.What is the feature you are proposing to solve the problem?
For example, we can add
binary
format orcompile
property inBun.build
or add newBun.compile
API with esbuild/Bun compability pluginsWhat alternatives have you considered?
Compile already bundled code (An inconvenient unnecessary step)
The text was updated successfully, but these errors were encountered: