Ticker

6/recent/ticker-posts

Ad Code

yarn global add @vue/cli is failing for node 14 due to inquirer/external-editor

Fixing yarn global add @vue/cli Installation Failure on Node.js 14

If you’ve tried running:

yarn global add @vue/cli

on Node.js 14, you may have noticed the installation failing recently—even though Vue CLI itself hasn’t changed in years.

Why This Happens

  • The latest version of Vue CLI is v5.0.8, released in July 2022.
  • Vue CLI depends on the Inquirer library (used for interactive prompts).
  • Inquirer now depends on a package called @inquirer/external-editor.
  • Recently, @inquirer/external-editor released v1.0.0, which requires Node.js 18+.

As a result, when installing Vue CLI on Node.js 14, Yarn fetches the latest dependency versions and fails due to the stricter Node version requirement.

Temporary Fix

If you’re still on Node.js 14, you can bypass the engine check by running:

yarn global add @vue/cli --ignore-engines

(Note: the flag is --ignore-engines, not --ignore-engine.)

This tells Yarn to skip the Node version requirement so Vue CLI can still be installed.

Recommended Fix

The best solution is to upgrade Node.js to v18 or later, since Node.js 14 has already reached its end of life. Upgrading ensures compatibility with the latest dependencies and keeps your environment secure.


In summary: This error isn’t due to Vue CLI itself, but rather a transitive dependency (@inquirer/external-editor) that dropped support for Node.js 14. Use --ignore-engines if you need a quick fix, but upgrade to Node 18+ for a long-term solution.

Post a Comment

0 Comments