1

Pointing to breakpoint VS2015-Update1 pops up ‘The breakpoint will not currently be hit. No symbols have been loaded for this document’ *.js.map is generated next to my *.js in my wwwroot/app directory. The project is all working fine. I tried debugging under Chrome also but I can`t drop breakpoint in sources/scripts/app.ts because it is empty. My web.config amended by:

<staticContent>
    <remove fileExtension=".ts" />
    <mimeMap fileExtension=".ts" mimeType="application/x-typescript" />
</staticContent>

and

tsconfig.json has the "sourceMap": true

Could anyone help or link me a VS2015 Angular2 hello word where I can hit breakpoint?

Project tree - png

import { bootstrap } from 'angular2/platform/browser';
import { Component, View } from 'angular2/core';
import { NgFor } from 'angular2/common';
import { FORM_DIRECTIVES } from 'angular2/common';

@Component({
    selector: "my-app"
})
@View({
    template: `
    {{message}}
    <br/><input [(ngModel)]="message"/>
    `,
    directives: [FORM_DIRECTIVES]
})

class AppComponent {
    message: string = "Hello word";
}

bootstrap(AppComponent);

message: string = "Hello word"; - here I put the breakpoint

3
  • You need to fill in more details about the context – this doesn't make much sense as-is. What is the relationship between Visual Studio and Chrome? The question sounds unanswerable without a more complete picture of the problem. Commented Jan 4, 2016 at 20:23
  • The relation is I currently host it by IIS Express from VS2015 but you are all right it is basically two questions first is related to VS2015 debugging while the second is for the Chrome ts debugging Commented Jan 4, 2016 at 20:49
  • I probably don't know enough about how VS+Chrome works. The notion they are connected seems odd to me. Looking at the code, Chrome is probably not involved, since you're setting a VS breakpoint. Regardless I think this question is not answerable as-is. Edit it down to a single one. Commented Jan 4, 2016 at 23:08

1 Answer 1

1

You are using ASP.NET 5 project template (according to the uploaded Project Tree - png). ASP.NET 5 is still in RC so i'm sure that debugging features will be improved but typescript debugging should have worked in Chrome. Please make sure to set the correct relative path in map file to the .ts source and also make sure the source file really exists in the proper directory under wwwroot. If it's not set correctly you see a blank .ts file (as you described) while you are debugging in Chrome.

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

1 Comment

Thx, I moved the scripts - ts directory under wwwroot. Chrome debug is fine from now on.

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.