Skip to content

Commit

Permalink
(docs): document how to configure multiple entry files
Browse files Browse the repository at this point in the history
- use the same example as in the tests
  • Loading branch information
agilgur5 committed Mar 6, 2020
1 parent 501c32f commit 9eab4e8
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ Despite all the recent hype, setting up a new TypeScript (x React) library can b
- [`tsdx build`](#tsdx-build)
- [`tsdx test`](#tsdx-test)
- [`tsdx lint`](#tsdx-lint)
- [Multiple Entry Files](#multiple-entry-files)
- [Contributing](#contributing)
- [Author](#author)
- [License](#license)
Expand Down Expand Up @@ -496,6 +497,17 @@ Examples
$ tsdx lint src --report-file report.json
```
### Multiple Entry Files
You can run `tsdx watch` or `tsdx build` with multiple entry files, for example:
```shell
tsdx build --entry src/index.ts --entry src/foo.ts
# outputs dist/index.js dist/foo.js and their respective formats and declarations
```
When given multiple entries, TSDX will output separate bundles for each file for each format, as well as their declarations. Each file will be output to `dist/` with the same name it has in the `src/` directory.
## Contributing
Please see the [Contributing Guidelines](./CONTRIBUTING.md).
Expand Down

0 comments on commit 9eab4e8

Please sign in to comment.