Angural 11 issues and its solutions while creating crud operation
Prem Murmu
on
4/23/2021 4:59:55 AM
I was trying to create crud operation on angular 11 first time. I am faced some issues where i stucked and later i found their solutions.
If you face issues like this while working on angular might help you out and save you time.
Error:
1.
ng : The term 'ng' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was
included, verify that the path is correct and try again.
At line:1 char:1
+ ng new my-crud-app --routing
+ ~~
+ CategoryInfo : ObjectNotFound: (ng:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNot FoundException
Solutions:
Above error shows that either angular/cli or angular platform variable not set up in you system. So for that you have to first check:
1. Correct Node installed on your system ( check node version " node -v "), if not installed install it (click)
2. Go to project folder and execute command: npm install -g @angular/cli
Above tips will work fine. If not comment below.
2.
ng : File C:\Users...ng.ps1 cannot be loaded because running scripts is disabled on this system. For more information
At line:1 char:1
+ ng new my-crud-app --routing
+ ~~
+ CategoryInfo : SecurityError: (:) [], PSSecurityException
+ FullyQualifiedErrorId : UnauthorizedAccess
Solutions:
Above error means there is problem with script execution policy, need to set proper scope and policy set to enable it.
As an Administrator, you can set the execution policy following command
in powershell window
Set-ExecutionPolicy RemoteSigned
in CMD window (open as admin mode)
powershell Set-ExecutionPolicy RemoteSigned
Above tips will work fine. If not comment below.
0 Comments on this post
Comments(0)||Login to Comments
- see more..
Categories
ALLAsp.Net (3)
Sitecore (11)
Issues Resolved (9)
Sitecore 9.3 (2)
International Business (1)
Innovations in Industries (3)
Supply Chain Management (1)
Industrial Engineering (14)
Sitecore 10 (4)
Sharepoint (1)
Azure (3)
Cloud Computing (1)
Online Courses (1)
Online Resources (2)
C# (1)
Blazor WebAssembly (2)
Sitecore form (1)
MS Sql Server (1)
Angular 11 (2)
Automobile Engineering (5)
Sitecore powershell (1)
Devops (2)
Microservice Architecture (1)
Sitecore Interview Questions (2)
Dotnet interview questions (1)
Sitecore useful links (1)
Privacy&Cookies (2)
Solr Search (2)
JavaScript (1)
sitecore xm cloud (2)