Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8630439
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T09:03:57+00:00 2026-06-12T09:03:57+00:00

Is there a way to debug TypeScript source in Visual Studio (instead of debugging

  • 0

Is there a way to debug TypeScript source in Visual Studio (instead of debugging the generated javascript)?

From the TypeScript language specifications:

TypeScript optionally provides source maps, enabling source-level debugging.

I was therefore expecting to be able to place breakpoints in ts code and be able to debug it, but it doesn’t work. I didn’t find any other mentions of debugging in the specs. Is there anything I should do to make this work? Perhaps the word “optionally” hints that I need to do something for it to work… Any suggestions?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T09:03:58+00:00Added an answer on June 12, 2026 at 9:03 am

    Current Answer for VS2017 and later

    Debugging Typescript directly in Visual Studio has been possible since VS2017. From the documentation:

    You can debug JavaScript and TypeScript code using Visual Studio. You can set and hit breakpoints, attach the debugger, inspect variables, view the call stack, and use other debugging features.

    There are also additional resources on Debugging Typescript / Asp.NET Core in Visual Studio.

    It is also possible to debug typescript in Visual Studio Code:

    Visual Studio Code supports TypeScript debugging through its built-in Node.js debugger and also through extensions like Debugger for Chrome to support client-side TypeScript debugging.

    Original Answer for prior versions of VS:

    You may not be able to debug in VS, but you can in some browsers. Aaron Powell has blogged about getting breakpoints working in Chrome Canary just today: https://www.aaron-powell.com/posts/2012-10-03-typescript-source-maps/.

    To summarise (very briefly) what Aaron says, you use the -sourcemap switch on the compiler to generate a *.js.map file in the same directory as your source. In browsers which support source maps (Chrome Canary, and presumably recent Firefox builds, since they are a Mozilla idea), you can then debug your .ts source just as you would normal .js files.

    The blog finishes with “Hopefully either the Visual Studio or IE (or both) team also pick up Source Maps and add support for them too.” – which suggests it hasn’t happened yet.

    Update:

    With the release of TypeScript 0.8.1, Source Map debugging is now also available in Visual Studio:

    https://blogs.msdn.com/b/typescript/archive/2012/11/15/announcing-typescript-0-8-1.aspx

    From the announcement:

    Debugging
    TypeScript now supports source level debugging! The source map format
    has been gaining popularity as a way of debugging languages which
    translate to JavaScript and is supported by a variety of browsers and
    tools. With version 0.8.1, the TypeScript compiler officially
    supports source maps. Additionally, the new version of TypeScript for
    Visual Studio 2012 supports debugging using the source map format.
    From the command-line, we now fully support the use of the –sourcemap flag, which outputs a source map file corresponding to the JavaScript output. This file will allow directly debugging the
    original TypeScript source in source map-enabled browsers and Visual
    Studio.
    To enable debugging in Visual Studio select ‘Debug’ from the dropdown after creating an HTML Application with TypeScript project.

    Update:

    WebStorm has also added support for debugging via SourceMaps: http://blog.jetbrains.com/webide/2013/03/webstorm-6-0-released-adds-typescript-debugging-with-source-maps-fresh-ui-and-much-more/

    First, WebStorm allows for smarter and more streamlined web
    development with modern languages such as TypeScript, CoffeeScript and
    Dart. In addition to providing a first-class code editor for these
    languages, WebStorm 6 offers:

    Automatic compilation/transpilation of these higher-level languages
    into those recognized by browsers on all supported platforms.
    Full-featured debugging of TypeScript, Dart or CoffeeScript with
    source maps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any way to debug a single file in Visual Studio.NET? I'm still
Is there a way to debug external exe using visual studio 2010 by shift+double
Is there a way to view the latest debug message instead of having to
Is there any way to debug a call coming from an AJAX post? This
Is there a way to debug code on Visual C++ 2008 Express, such as
Since MacGDBp from bluestatic.org seems to be discontinued, is there another way to debug
Is there a way to debug XSLT documents that are loaded from a database
Is there a way to debug .Net dll from SSIS Script Component which is
is there a way to debug all/single tests in Aptana Studio / Eclipse? ruby-debug19
Is there any way to debug a JavaScript page runing on iPad?

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.