Is there a way with gulp serve to get a trace of TypeScript statements that are executed in a SPFx client application ?
-
Can you explain a little bit what you are trying to achieve? Are you looking for logging to the console? Stack traces at various points in your code?– PatMill_MSFTCommented Sep 23, 2016 at 15:56
-
I am looking for being able to log statements that have been executed to a console.– Nigel PriceCommented Sep 24, 2016 at 19:55
-
1So are you looking for a stack trace on every function call? Logging when specific actions take place? Take a look at this post and see if it serves your needs - github.com/SharePoint/sp-dev-docs/wiki/…– PatMill_MSFTCommented Sep 26, 2016 at 17:52
Add a comment
|
1 Answer
There is some logging support built into the framework. Documentation can be found here - https://github.com/SharePoint/sp-dev-docs/wiki/Working-with-the-Logging-API , and a blog post by Wictor here - http://www.wictorwilen.se/sharepoint-framework-nuggets-logging-like-a-pro