Is there a wildcard option to tell Bun to bundle all files of a specific type?
Here is what I have now:
<code>// bun.build.js
import html from 'bun-plugin-html';
await Bun.build({
entrypoints: ['./index.html', './page1.html', './page2.html', ..., './page1000.html', ...],
publicPath: "public",
sourcemap: "inline",
outdir: './public',
plugins: [
html()
],
});
</code>
<code>// bun.build.js
import html from 'bun-plugin-html';
await Bun.build({
entrypoints: ['./index.html', './page1.html', './page2.html', ..., './page1000.html', ...],
publicPath: "public",
sourcemap: "inline",
outdir: './public',
plugins: [
html()
],
});
</code>
// bun.build.js
import html from 'bun-plugin-html';
await Bun.build({
entrypoints: ['./index.html', './page1.html', './page2.html', ..., './page1000.html', ...],
publicPath: "public",
sourcemap: "inline",
outdir: './public',
plugins: [
html()
],
});
Is there a way to all HTML files or all TypeScript files in a directory?
I’m guessing it would look something like this:
<code>// bun.build.js
import html from 'bun-plugin-html';
await Bun.build({
indir: ['./public'], // pseudo code input directory
fileTypes: ['html', 'ts'], // pseudo code compile all files with html or ts extension
sourcemap: "inline",
outdir: './public',
plugins: [
html()
],
});
</code>
<code>// bun.build.js
import html from 'bun-plugin-html';
await Bun.build({
indir: ['./public'], // pseudo code input directory
fileTypes: ['html', 'ts'], // pseudo code compile all files with html or ts extension
sourcemap: "inline",
outdir: './public',
plugins: [
html()
],
});
</code>
// bun.build.js
import html from 'bun-plugin-html';
await Bun.build({
indir: ['./public'], // pseudo code input directory
fileTypes: ['html', 'ts'], // pseudo code compile all files with html or ts extension
sourcemap: "inline",
outdir: './public',
plugins: [
html()
],
});