generated from productdevbookcom/ts-bundle-template
-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: zero dependencies and only esm support * fix: lint * fix: esm export * fix: lint * fix: export * fix: cjs
- Loading branch information
1 parent
99cdec1
commit 3d60839
Showing
4 changed files
with
16 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,14 @@ | ||
import type { Options } from 'tsup' | ||
|
||
import pkg from './package.json' | ||
|
||
const external = [ | ||
...Object.keys(pkg.dependencies || {}), | ||
] | ||
|
||
export default <Options>{ | ||
entryPoints: ['src/index.ts'], | ||
outDir: 'dist', | ||
format: ['esm', 'cjs'], | ||
sourcemap: true, | ||
sourcemap: false, | ||
clean: true, | ||
dts: true, | ||
minify: true, | ||
external, | ||
noExternal: [ | ||
'ofetch', | ||
], | ||
} |