0

I have developed an SPFX webpart which overrides the existing classes on SitePage. I need to run the webpart on sitepage without actually deploying it.

When i gulp serve it open local workbench and my webpart displays there but I want to add it on site page and see if the functionality is working fine before deploying it

1 Answer 1

2

You can use the following process:

  1. Start the local server using gulp serve --nobrowser
  2. Navigate to the site page you want to test
  3. Add ?loadSPFX=true &debugManifestsFile=https://localhost:4321/temp/manifests.js to the query string
  4. Click the Load debug scripts button in the Allow debug scripts? dialog to confirm you want to run scripts running locally
  5. Add the web part to the page to test

See Debug SharePoint Framework solutions on modern SharePoint pages | Debug SharePoint Framework web parts on modern SharePoint pages for more information.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.