Angular 2 Errors and Typescript - how to debug?

前端 未结 4 449
我寻月下人不归
我寻月下人不归 2021-02-03 18:53

I\'ve just started a project to learn Angular2 and Typescript+Javascript. I come from a Java background and my approach to debugging projects is usually a combination of stack t

4条回答
  •  北恋
    北恋 (楼主)
    2021-02-03 19:27

    If you are coming from the Java world, there's a good chance you are already using IntelliJ IDEA from JetBrains. If so, then it is possible to debug JavaScript (and TypeScript) applications directly in the IDE using the same interface you use for Java applications.

    JetBrains has some documentation on the subject that might help.

    As was said in other answers, you can also use the Chrome Inspector's debugger. Personally, I greatly prefer using IntelliJ to do that instead.

    If you are just looking for examples on how the workflow goes, then take a look at this Github project that shows the use of Webpack with Angular2.

提交回复
热议问题