By using this site, you acknowledge that you have read and understand our Cookie policy, Privacy policy and Terms .
close

Angular

Angular related

rss_feed Subscribe RSS

Problem

When you follow Angular CLI installation guide in Windows, you may encounter the following error:

ng is not recognized as an internal or external command

The resolutions are available in the following link:

https://stackoverflow.com/questions/37991556/ng-is-not-recognized-as-an-internal-or-external-command

This post adds more details about how to check your npm package location as each individual may have installed it in different places.

Resolution

Open a Command Prompt and type the following command to check your prefix:

npm config get prefix

In my machine, the prefix is ‘D:\Packages\npm’

image

Add the prefix location into your PATH environment variable.

*In my environment, I’ve added a configuration file ‘.npmrc’ in my user folder. In the file, it has the following content to configure the prefix location:

prefix = "D:\\Packages\\npm"

Then the Angular CLI commands should work properly like the following screenshot:

image

*Please note your nodejs version needs to be 8.9 or greater to run the CLI otherwise you may encounter an error like below:

You are running version v*.*.* of Node.js, which is not supported by Angular CLI v6.
The official Node.js version that is supported is 8.9 and greater.

Please visit https://nodejs.org/en/ to find instructions on how to update Node.js.

info Last modified by Raymond at 4 months ago * This page is subject to Site terms.

info About author

More from Kontext

local_offer lite-log local_offer spark local_offer pyspark

visibility 1487
thumb_up 0
access_time 8 months ago

When creating Spark date frame using schemas, you may encounter errors about “field **: **Type can not accept object ** in type <class '*'>”. The actual error can vary, for instances, the following are some examples: field xxx: BooleanType can not accept object 100 in type ...

open_in_new View

local_offer lite-log local_offer hive

visibility 785
thumb_up 0
access_time 11 months ago

Since Hive 3.x, new authentication feature for HiveServer2 client is added. When starting HiveServer2 service (Hive version 3.0.0), you may encounter errors like: ‘HiveServer2 metastore.RetryingMetaStoreClient: RetryingMetaStoreClient trying reconnect as [username]  (auth:S...

open_in_new View

local_offer lite-log local_offer linux local_offer WSL local_offer ubuntu

visibility 1583
thumb_up 0
access_time 10 months ago

This page shows how to install Windows Subsystem for Linux (WSL) system on a non-system drive manually. Enable Windows Subsystem for Linux system feature Open PowerShell as Administrator and run the following command to enable WSL feature: Enable-WindowsOptionalFea...

open_in_new View

local_offer kontext local_offer lite-log

visibility 57
thumb_up 0
access_time 10 months ago

In the past months, this website has been using the following Email address to delivery all the notification messages to the website users such as registration confirmation email, comment email and so on. no-reply[at]kontext.tech However, I recently found that...

open_in_new View

comment Comments (3)

comment Add comment

Please log in or register to comment. account_circle Log in person_add Register
account_circle Mr.Captain
reply Reply
account_circle Sujit Sonarghare

Plesae solved my problem


reply Reply
account_circle Rama

ng is not recognized as an internal or external command (Windows 10)


reply Reply
Kontext Column

Kontext Column

Created for everyone to publish data, programming and cloud related articles. Follow three steps to create your columns.

Learn more arrow_forward
info Follow us on Twitter to get the latest article updates. Follow us