Contents
When you add a SharePoint Framework extension to your project, the SharePoint Framework Yeoman generator will extend your project’s configuration. Using this configuration, you can automatically start a modern SharePoint page in your web browser with all parameters required to debug the extension on that page already present.
gulp serve –config=helloWorld After running this command, gulp will start your web browser with the modern page specified in your configuration. The page will show a popup asking you to confirm that you now will be loading debug scripts. Once you confirm, the page will load with the extensions you specified in your serve configuration.
How to debug customizers in modern SharePoint?
To debug an Application Customizer, add the following to the URL of your modern page: Line breaks & indentation have been added to the following snippet for readability. The following text should be on a single line with no whitespace.
To test the local versions of your SharePoint Framework client-side web parts on modern SharePoint pages in your tenant, first, start the local gulp server, by changing the working directory to your project folder and executing in the command line: Next, in the web browser, navigate to the modern page, on which you want to test the web parts.
To reverse the changes and disable debugging, change the following XML in the web.config file: When you run your SharePoint project in debug mode, the SharePoint deployment process performs the following tasks: Runs the customizable pre-deployment commands. Creates a Web solution package (.wsp) file by using MSBuild commands.
How to debug JavaScript in Microsoft Edge browser?
Debug your Javascript code running in Microsoft Edge from VS Code and Visual Studio. A VS Code extension to debug your Javascript code in the Microsoft Edge browser. This is also used to enable Javascript debugging inside the Microsoft Edge browser when launched from ASP.Net Projects in Visual Studio.