@sunney/create-ts-app
Advanced tools
Comparing version 2.0.13 to 2.0.14
{ | ||
"name": "@sunney/create-ts-app", | ||
"version": "2.0.13", | ||
"version": "2.0.14", | ||
"description": "Create a TypeScript app with a single command", | ||
@@ -5,0 +5,0 @@ "publishConfig": { |
@@ -1,12 +0,24 @@ | ||
import { defineConfig } from "tsup"; | ||
import { defineConfig, type Options } from "tsup"; | ||
export default defineConfig((options) => ({ | ||
entry: ["src/index.ts"], | ||
sourcemap: !options.watch, | ||
minify: !options.watch, | ||
clean: !options.watch, | ||
format: options.watch ? ["esm"] : ["cjs", "esm"], | ||
dts: true, | ||
outDir: "lib", | ||
onSuccess: options.watch ? "node lib/index.mjs" : undefined, | ||
})); | ||
export default defineConfig((flags) => { | ||
const buildOptions: Options = { | ||
minify: true, | ||
clean: true, | ||
format: ["cjs", "esm"], | ||
dts: true, | ||
}; | ||
const devOptions: Options = { | ||
sourcemap: true, | ||
format: ["esm"], | ||
onSuccess: "node ./dist/index.mjs", | ||
}; | ||
const options = flags.watch ? devOptions : buildOptions; | ||
return { | ||
entry: ["src/index.ts"], | ||
outDir: "dist", | ||
...options, | ||
}; | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
35661
46