-
-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find module '@schematics/angular/utility/parse-name' #241
Comments
Hi @kdmakwana43, Does your project have a dependency on npm install -D @angular/cli |
This worked for me. |
That works for me. Love you! :) |
I just login to say it work and thank you |
Thanks! It works for me! |
These Commands Collectively helped me |
The following fixed the issue for me :
|
Nothing helped me. First, I had an error:
Running After running Error: Invalid rule result: Instance of class Promise. |
Hey @AndrePu , |
I am also have this problem when trying to use the cli to generate a component: I've done all the steps suggested above including updating the angular dependencies. |
I created a new project based on this template: tns create --template tns-template-drawer-navigation-ng Attempted to create a component: tns generate c home/test and received this error: Next ran: npm i --save-dev @nativescript/schematics Uninstalled @nativescript/schematics Installed @nativescript/schematics |
I went back to my old project, and because I had deleted the package-lock.json I decided to run: npm i @nativescript/angular And now I can generate a component. |
Saved my day. Thank you! |
typescript has been moved to @schematics/angular/node_modules/typescript/lib/typescript" |
hello, I have installed the npm i @nativescript/angular and npm install -D @angular/cli but nothing helped so far. Anybody any idea what else I can try or another way to install Angular Material? |
typescript has been moved to @schematics/angular/node_modules/typescript/lib/typescript" |
@realivatesolutions thank you! |
This working for me ! |
These two commands also helped me |
when I try to add --> ng add @angular/material to my new project throwing me a error
Anyone help me how to solve it. |
I am experiencing the same issue but with normal ng generate component command. |
Same issue with ng generate component. |
Inspecting an old project, found "project.d.ts" and "project.js" under "@schematics\angular\utility". Just copied those 2 files to my new project, and it worked. Surely not a good practice tho. |
Same issue with ng g c newcomponent I tried all previous steps but nothing worked for me |
Trying to add a component with: I get this:
These are my current versions: Something about the Schematics that screw this up it seems... |
@Holei94 I had the same issue after updating my I also tried the various other suggestions, such as installing TLDR: I downgraded to v 9.x.x of the |
An unhandled exception occurred: Cannot find module '@schematics/angular/utility/project'Hi all.
Then I get this:
I have tried to run the commands above:
But unfortunately the issue persist To be honest I do not know what is the problem, I would appreciate any help to fix it. |
Downgrade @angular/cli to 9.1.8, just as above poster said. |
Thanks dude. Gracias amigo. I Downgraded just the dependency @schematics and it works now.
|
the normal solution to try is :
make sure you have nativescript/schematics in your package.json . otherwise add it with :
if you still get the same problem, this because you have incompatible version between dependencies ,for example @angular/cli@10.x.x and nativescript/schematics@9.x.x . in this case you have to downgrade the appropriate dependency to 9.x.x :
|
this work, thank you: |
Does this solution work for the same error encountered in a code sharing environment? When I run:
Then going to the log, I see this:
Thanks in advance! |
@JasonEdLewis looks like you have old incorrect version installed globally:
The latest is 10.0.1 |
Thank you soo much Nathan!! I appreciate your work on this project, your time and you getting me over this hurdle!! |
This worked for me. |
This may be an issue with my versions now but after following all the above steps I get another error. "devDependencies": { Furthermore with this other configuration of devDependencies I get a different error.
desired would not need the skip flag, update app.component, and generate files without .tns bc its mobile only |
Same here, i hope someone could help. |
I installed @nativescript/schematics@0.7.0 for my Nativescript project and tried to generate component using command its show me following error.
An unhandled exception occurred: Cannot find module '@schematics/angular/utility/parse-name'
See "/private/var/folders/g0/3gly57n500zb1xvl7rffy_100000gn/T/ng-Mxey0g/angular-errors.log" for further details.
here is errors.log
[error] Error: Cannot find module '@schematics/angular/utility/parse-name'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
at Function.Module._load (internal/modules/cjs/loader.js:562:25)
at Module.require (internal/modules/cjs/loader.js:690:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object. (/Users/apple/Codenatial/nativescript/demo/node_modules/@nativescript/schematics/src/generate/component/index.js:6:22)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
when I downgrade @nativescript/schematics@0.7.0 to @nativescript/schematics@0.6.0 its working fine.
The text was updated successfully, but these errors were encountered: