Skip to content

Commit

Permalink
fix: bundle CLI with Vite
Browse files Browse the repository at this point in the history
  • Loading branch information
benmccann committed Feb 3, 2024
1 parent 329659b commit 65e1057
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 5 deletions.
4 changes: 4 additions & 0 deletions cli/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,11 @@
"ts-node": "^10.9.1",
"tslib": "^2.5.3",
"typescript": "^5.3.3",
"vite": "^5.0.12",
"vitest": "^1.2.1"
},
"scripts": {
"build": "tsc --project tsconfig.build.json",
"build": "vite build --ssr",
"lint": "eslint \"src/**/*.ts\" \"test/**/*.ts\" --max-warnings 0",
"lint:fix": "npm run lint -- --fix",
"prepack": "npm run build",
Expand Down
4 changes: 0 additions & 4 deletions cli/tsconfig.build.json

This file was deleted.

12 changes: 12 additions & 0 deletions cli/vite.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { defineConfig } from 'vite'

export default defineConfig({
build: {
rollupOptions: {
input: 'src/index.ts',
output: {
dir: 'dist'
}
}
}
})

0 comments on commit 65e1057

Please sign in to comment.