2

I am starting to learn angular2

and I happened to clone the Angular 2 Quickstart from github

Now, what I noticed is that, some of the statements in typescript files are shown as errors in Visual Studio, but they actually work

enter image description here

I checked a similar question which was resolved by installing MVC4 in the machine.

What should I install/do to fix this?

1 Answer 1

1

In my experience Visual Studio is a bit unstable with regards to this on-the-fly sync and compile. What helped me is just a simple restarting of Visual Studio (if all other stuff is in order).

If that does not help, it's better to update TypeScript to latest version. I do it first thing in Visual Studio. You cannot do it directly from extension tab unfortunately, so you need to download it from MS site.

P.S. The Url might change later of course if new versions are released.

Sign up to request clarification or add additional context in comments.

3 Comments

But you are saying that you have proper .js files in there and if you do a change it will recompile and change the .js file as well?
Another thing - did you try to update typescript version? I do it first thing in Visual Studio. You cannot do it directly from extension tab unfortunately, so you need to download it from MS site (microsoft.com/en-us/download/details.aspx?id=48593)
it worked! pls add it to the answer :) upvoted and accepted

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.