vsavkin / router_mailapp

114 stars 45 forks source link

npm start fails with jasmine errors #13

Open javaspeak opened 6 years ago

javaspeak commented 6 years ago

Hi Victor,

Greetings.

I randomly came across your router_mailapp and youtube videos.

Thank you for your contributions and time spent helping the world Angular community.

To let you know:

npm start results in following errors:

ERROR in /Users/javaspeak/workspaces/43kare/router_mailapp/src/app/spec_utils.ts (4,3): Cannot find name 'jasmine'.

ERROR in /Users/javaspeak/workspaces/43kare/router_mailapp/node_modules/@types/jasmine/index.d.ts (117,52): '=' expected.

In the attached file, error.txt, you can see I ran commands:

npm list -g --depth=0
npm install
npm start

Am still learning so am not sure of the reason of the error. Thought it may be relevant though as other people may be encountering similar errors with your example.

I expect this to be an environmental version error - that my environment is differently or badly configured. However it may be because I am using newer version of stuff - am not sure.

Thank you for your contributions and time.

:-)

John

error.txt

javaspeak commented 6 years ago

I tried upgrading everything to Angular 5, changing angular-cli.json to use environmentSource, changing @angular-cli to @angular/cli, adding @angular/compiler-cli but still cannot run the example.

It seems like Angular versions are rushing past - hard to keep up :-)

Now I get problems like:

 Failed at the booknew@0.0.0 start script.

I do not know what booknew is.

I think someone with brains can upgrade the example to the latest of everything but since I am beginner with Angular it is proving harder than I guessed.

I noticed the router_mailapp example was using version 2 of Angular and had some beta stuff in it so it is normal it does not work now as we are now on version of 5 of Angular and that is too greater version change to hope for backward compatibility.

If anyone has brains and time to upgrade this example we will be truly happy.

:-)

Thank you

squirrelsRduck commented 6 years ago

Hi. The easiest way to get around this issue is to delete the ^ and ~ symbols from the package.json file. If you feel ambitious, you can try upgrading them. Deleting the ^ and ~ symbols gives some warnings about needing to install some other dependencies but it seemed to work as-is with the simple ^ and ~ modifications.