-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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
Improve error message when using --target lib and the entry file is missing #1051
Comments
Your build command should look like this: "build": "vue-cli-service build --target lib --name ff src/main.js", We should definitely show a better error when the entry file isnt' found. I would assume we have such a check, but it comes after the config setup that breaks with the shown error when building a lib. |
We should probably check if the entry file exists right around here: |
Will there be support for TypeScript (.ts) files in the future? |
I ran into this issue today (using This error can occur if you override the alias config in config.resolve.alias = myAliasConfig you should do something like this: config.resolve.alias = { ...config.resolve.alias, ...myAliasConfig } This also fixes the same issue when building web-components and the error is something like I hope this saves some of you a lot of time debugging. |
Version
3.0.0-beta.6
Reproduction link
https://github.com/fjc0k/vue-cli-lib-test
Steps to reproduce
What is expected?
build success
What is actually happening?
build failed with error:
notice: the main.js file is not default
The text was updated successfully, but these errors were encountered: