Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: use typescript for rollup configPlugin #8290

Merged
merged 1 commit into from May 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion package.json
Expand Up @@ -34,6 +34,7 @@
},
"devDependencies": {
"@microsoft/api-extractor": "^7.23.1",
"@rollup/plugin-typescript": "^8.3.2",
"@types/babel__core": "^7.1.19",
"@types/babel__standalone": "^7.1.4",
"@types/convert-source-map": "^1.5.2",
Expand Down Expand Up @@ -77,11 +78,11 @@
"prompts": "^2.4.2",
"rimraf": "^3.0.2",
"rollup": "^2.72.1",
"rollup-plugin-esbuild": "^4.9.1",
"semver": "^7.3.7",
"simple-git-hooks": "^2.7.0",
"sirv": "^2.0.2",
"ts-node": "^10.7.0",
"tslib": "^2.4.0",
"typescript": "^4.6.4",
"unbuild": "^0.7.4",
"vite": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion packages/vite/package.json
Expand Up @@ -47,7 +47,7 @@
"scripts": {
"dev": "rimraf dist && pnpm run build-bundle -w",
"build": "rimraf dist && run-s build-bundle build-types",
"build-bundle": "rollup --config rollup.config.ts --configPlugin esbuild",
"build-bundle": "rollup --config rollup.config.ts --configPlugin typescript",
"build-types": "run-s build-temp-types patch-types roll-types",
"build-temp-types": "tsc --emitDeclarationOnly --outDir temp/node -p src/node",
"patch-types": "esno scripts/patchTypes.ts",
Expand Down
2 changes: 2 additions & 0 deletions packages/vite/rollup.config.ts
Expand Up @@ -19,6 +19,7 @@ const envConfig = defineConfig({
input: path.resolve(__dirname, 'src/client/env.ts'),
plugins: [
typescript({
tsconfig: false,
target: 'es2020',
module: 'esnext',
include: ['src/client/env.ts'],
Expand All @@ -39,6 +40,7 @@ const clientConfig = defineConfig({
external: ['./env', '@vite/env'],
plugins: [
typescript({
tsconfig: false,
target: 'es2020',
include: ['src/client/**/*.ts'],
baseUrl: path.resolve(__dirname, 'src/client'),
Expand Down
9 changes: 9 additions & 0 deletions packages/vite/tsconfig.json
@@ -0,0 +1,9 @@
{
"extends": "./tsconfig.base.json",
"compilerOptions": {
"strict": false,
"declaration": false,
"resolveJsonModule": true
},
"include": ["./rollup.config.ts"]
}
36 changes: 19 additions & 17 deletions pnpm-lock.yaml

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