Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Cannot set breakpoint in *.ts files #4844


User avatar
0
TimMackey created

When running *.Web.Host, tooltip for breakpoint says "The breakpoint will not currently be hit. No symbols have been loaded for this document.

TypeScript Build tab in Properties for *.Web.Host has "Generate source maps" checked. directories are not checked and empty.


6 Answer(s)
  • User Avatar
    0
    BobIngham created

    @TimMackey - I'm having similar problems: [https://forum.aspnetboilerplate.com/viewtopic.php?f=5&t=10952&p=27841]). Something to do with source map locations after a build I think. I am still compromising during debug until I find the correct answer. Please post back if you find something, I will do the same.

  • User Avatar
    0
    alper created
    Support Team

    <cite>TimMackey: </cite> When running *.Web.Host, tooltip for breakpoint says "The breakpoint will not currently be hit. No symbols have been loaded for this document.

    TypeScript Build tab in Properties for *.Web.Host has "Generate source maps" checked. directories are not checked and empty.

    you might be running on Release Mode. Check your VS config

  • User Avatar
    0
    TimMackey created

    For all projects build Configuration is Debug, Platform is Any CPU

  • User Avatar
    0
    ismcagdas created
    Support Team

    @TimMackey if you are talking about angular project, it is not runned by visual studio, so you cannot add breakpoints using visual studio. You can add javascript debugger or you can check angular-cli documentation for that.

    If you are talking about server side Host project, then please let us know.

  • User Avatar
    0
    TimMackey created

    "Getting Started in Angular" says: "Run API Host Once you've done the configuration, you can run the application. Server side application only contains APIs. So, default page is a swagger UI which can be used to investigate the API:"

    The first line of this issue says "When running *.Web.Host, tooltip for breakpoint says "The breakpoint will not currently be hit. No symbols have been loaded for this document.""

    The breakpoing is on line 40 in the 'save()' method in *.Web.Host\src\account\shared\tenant-change-modal.component.ts

    I am reasonably sure this is server. Yes?

  • User Avatar
    0
    alper created
    Support Team

    hi,

    to debug TypeScript (*.ts) code you have to write

    debugger;
    

    into the save method in tenant-change-modal.component.ts

    [attachment=0:2a5vt33d]debug-typescript.jpg[/attachment:2a5vt33d]