2

I'm testing a newly created webpart locally using the gulp serve command after launching the gulp trust-dev-cert for certification installation, the local workbench opens up but all browsers are displaying the same error. Here's a screenshot from google chrome :

enter image description here

What I've tried :

  • Disabling firewall

I've googled and googled but with no success.

Does anyone have an idea about what's happening ?

2
  • definitely looks like a cert issue. Have you tried Fiddling? Or running trust-cert again? Nov 1, 2017 at 19:56
  • I've used Fiddler and it showed 200 http code. I've also removed the certificate using gulp "untrust-dev-cert" and reinstalled it again, no success.
    – KhalilG
    Nov 1, 2017 at 22:08

2 Answers 2

2

Try to give a look to the tip of Waldek Mastykarz if you are using latest LTS of Node.js here, it solved the issue for me (no need to disable firewall) : https://github.com/SharePoint/sp-dev-docs/issues/1002

1
  • Hi Patrick, thank you for your answer, it's working now. I've added a global environment variable like this : Key = "NODE_NO_HTTP2" and Value = "1". After that, we should close any command line or PowerShell session and restart again and it should be working.
    – KhalilG
    Nov 13, 2017 at 22:00
0

For Windows 10, Node version 8.9.1, SPFx version 1.4.0 below is the solution:

Add System variable

Control Panel -> System -> Advanced System Settings -> Environment Variables -> System Variables)

  • Variable name: NODE_NO_HTTP2
  • Variable value: 1

Don't forget to restart terminal.

1
  • These does not help in 2019. Look here for working solution: sharepoint.stackexchange.com/a/230115/5658
    – Gennady G
    Aug 6, 2019 at 15:04

Your Answer

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

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