Quantcast
Channel: Node.jsタグが付けられた新着記事 - Qiita
Viewing all articles
Browse latest Browse all 8695

Vue CLIをインストール後vue: command not foundになる

$
0
0

環境

  • macOS Catalina 10.15.7
  • Node.js 14.16.0
  • npm 7.6.3

現象

1.Vue CLIをグローバルにインストール

 $ yarn global add @vue/cli

2.インストール完了後、バージョン確認のコマンドを打つと「command not found」と言われる

$ vue --version
nodenv: vue: command not found

The `vue' command exists in these Node versions:
  10.15.1
  10.16.0

解決

以下のコマンドでPATH変数を更新

export PATH=$PATH:/Users/denis/.npm-global/bin

返ってきた…!

$ vue --version
@vue/cli 4.5.11

参考記事

node.js — Vueコマンドが見つかりません
コマンドや環境設定でよく躓いてしまうので、右往左往してこちらにたどり着きました。
ありがとうございました!!


Viewing all articles
Browse latest Browse all 8695

Trending Articles