Skip to content

Typescript definition files errors #28

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

Closed
hobojoe opened this issue Nov 19, 2016 · 8 comments
Closed

Typescript definition files errors #28

hobojoe opened this issue Nov 19, 2016 · 8 comments

Comments

@hobojoe
Copy link

hobojoe commented Nov 19, 2016

Hi,

First of all I would like to thank you for the great tutorial on Angular2 SPA.

I've downloaded the complete solution but I can't seem to build it because I am facing TS definition files errors.

Property 'map' does not exist on type 'Observable<Response>'
image

It keeps complaining on the angular definition files as if they couldn't be found.

I have followed all the installation steps described on the blog, I have even reinstalled VS but still no luck.

Am I missing something?

I have Visual Studio 2015 Community.

I have also tried on VS Code, same problem.

Can anyone assist me? Thanks

@chsakell
Copy link
Owner

Make sure you follow the instructions on the README.md file. For start, it seems that you haven't downloaded the npm packages.

@hobojoe
Copy link
Author

hobojoe commented Nov 21, 2016

Hi,

I followed the instructions and installed everything. The npm packages are installed. If I check the node_modules folder has all the needed files I even managed to find the one which declares de MAP function missing on my errors but for some reason VS does not recognize them.

I tried using your complete code and also by following the blog post and creating my own solution. The issue is the same.

I am not sure what could be the problem.

Any other ideas?

Thanks

@chsakell
Copy link
Owner

Have you installed the latest TypeScript version for VS 2015? This might help you.

@hobojoe
Copy link
Author

hobojoe commented Nov 21, 2016

Hi, I believe I have 2.0.10 installed.

When I get home I'll double check and let you know.

@hobojoe
Copy link
Author

hobojoe commented Nov 21, 2016

Hi,

I do have the TS version 2.0.10 installed.

After installing the Typescript for VS2015 your solution started working, the errors are gone.

I then went to the project I was creating by following you blog post but unfortunately the errors persist on it. I've checked everything and it seems correct.

So in order to double check I started a brand new project, followed your blog post up until the angular part where I only added the data.service.ts file to check if it would work. It didn't - same errors.

I have added this new solution to github:
https://github.com/hobojoe/TestApp

If you could check and see if I am missing something it would be great.

I am looking forward to start using your "template" on my new app and this TS thing is killing me!

Thanks in advance!

@hobojoe
Copy link
Author

hobojoe commented Dec 1, 2016

Any thoughts on what might be the issue?

Thanks

@marcelo-maciel
Copy link

@hobojoe i installed a new machine with win10 and had many errors, including few map errors.
I solved my issues running again all global npm commands and after instaling 'typings' again, in same folder of appsettings.json.

I also installed these apps:
DotNetCore.1.0.1-SDK.1.0.0.Preview2-003133-x64.exe
DotNetCore.1.0.1-VS2015Tools.Preview2.0.3.exe
dotnet-dev-win-x64.1.0.0-preview2-1-003177.exe
And all VS2015 updates.

@VahidN
Copy link

VahidN commented Dec 1, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants