-
-
Notifications
You must be signed in to change notification settings - Fork 9k
Closed
Description
Version
3.2.31
Reproduction link
Steps to reproduce
This project is created by create-vite:
pnpm create vite project -- --template vue-tsUpdate dependencies to the latest version then change src/main.ts to src/index.ts:
{
"devDependencies": {
"@vitejs/plugin-vue": "^2.2.4",
"typescript": "^4.6.3",
"vite": "^2.8.6",
"vue-tsc": "^0.33.7"
}
}import App from './App.vue'
export default AppChange vite.config.ts to build lib:
import { resolve } from 'path'
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
// https://vitejs.dev/config/
export default defineConfig({
build: {
lib: {
entry: resolve(__dirname, 'src/index.ts'),
name: 'Test',
formats: ['es'],
fileName: 'test'
},
rollupOptions: {
external: ['vue']
}
},
plugins: [
vue()
]
})Install project and run:
pnpm run buildWhat is expected?
Build successful.
What is actually happening?
Will take some errors and build fail.
If this is just a problem of vue-tsc (volar), please help migrate this issue, thanks.
Metadata
Metadata
Assignees
Labels
No labels
