-
-
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
feat: simple typescript support #51
Conversation
This is great, but I think TS's transpilation itself is too slow for dev purposes, especially for a speed-focused dev. server like vite. There are a number of alternative (and much faster) TS -> ESnext compilers available (e.g. Surcrase, esbuild, swc) and I'm still researching what is the best compiler to use in vite. |
Also, what's the expected result when TypeScript is being used? Should the server only strip types, and we leave the type checking to an IDE? Or should the server send back 500 errors (or something) to help the dev experience in catching type errors? |
Time To Close This PR |
I noticed the latest code uses esbuild, for what reason? |
@zzetao support minification with esbuild |
# Conflicts: # src/node/server.ts # src/node/serverPluginVue.ts
@zzetao .Sorry. I pull the code just now.Look like esbuild is already integrated. |
Closing since we are using |
@yyx990803 . I change my pr code with use |
Oh I didn't realize - but it should actually be fixed already. The rewrite happens after TS transpilation and the logic doesn't need to be duplicated. TS file extension resolution had a bug that is now fixed in ca421cd |
fix #6