#Multiple Entrypoints with Nested Directories

1 messages · Page 1 of 1 (latest)

fringe yarrow
#

Here is my project structure:

|-src/
|-|-lib/
|-|-|-LibComponent1.ts
|-|-|-LibComponent2.ts
|-|-index.ts
|-|-page2.ts

Is there a way for bun.build to build this project into:

|-dist/
|-|-lib/
|-|-|-libComponent1.js
|-|-|-libComponent2.js
|-|-index.js
|-|-page2.js
charred laurel
#

something like this on the command line will work

bun build src/**/*.ts --outdir dist
#

src/**/*.ts will be expanded to match every typescript file in src and each one will be treated as a separate entrypoint

#

which may or may not be what you want