-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
define not working with typescript vue template #6006
Comments
This is a type error, not a build error. If you remove |
Thanks @bluwy but I still consider it a build error. By default, and by using a documented feature, the build fails. Maybe the docs should be updated for the define section? |
Oops I didn't realize it's // src/env.d.ts
declare const __BUILD_DATE: string; Yes, I think a small note in the |
Fantastic, thanks for your help |
Describe the bug
Using the vue-ts template, and defining a variable in the define section of the vite config, throws an error when building (works in dev)
Reproduction
create a new vite vue-ts template project
vite.config.ts
main.ts
and then run build
System Info
Used Package Manager
pnpm
Logs
Validations
The text was updated successfully, but these errors were encountered: