vue-cli-service: command not found
时间: 2023-09-04 19:06:40 浏览: 346
vue-cli4-vant:基于vue-cli4和vant的移动端开发模板
As an AI language model, I do not have the context of your situation, but I can suggest some general solutions.
This error message usually occurs when the Vue CLI is not installed globally on your system or the path to the Vue CLI is not set in your system's environment variables.
To solve this issue, you can try the following:
1. Install the Vue CLI globally by running the following command in your terminal:
```
npm install -g @vue/cli
```
2. Make sure the path to the Vue CLI is set in your system's environment variables. You can check this by running the following command:
```
echo $PATH
```
If the path to the Vue CLI is not included in the output, you can add it to your system's environment variables by editing the `.bashrc` or `.bash_profile` file in your home directory and adding the following line:
```
export PATH="$PATH:/usr/local/bin"
```
Note: replace `/usr/local/bin` with the path to your Vue CLI installation.
3. If you have installed the Vue CLI locally in your project, you can run the command using `npm run` like this:
```
npm run vue-cli-service <command>
```
For example:
```
npm run vue-cli-service serve
```
I hope this helps!
阅读全文