I am creating SPFX webpart. Without doing any code changes i am executing gulp serve. I am getting below error for this. What could be the issue?

enter image description here

GULP version:

CLI version: 2.2.0 Local version: 4.0.2

2 Answers 2


I suspect you're using node 12 and gulp 3. That combination does not work: https://github.com/gulpjs/gulp/issues/2324

A previous workaround from Jan. does not work either: https://github.com/gulpjs/gulp/issues/2246

Solution: Either upgrade to gulp 4 or downgrade to an earlier node.

Reference: https://stackoverflow.com/questions/55921442/how-to-fix-referenceerror-primordials-is-not-defined-in-node

  • Thanks Ravi, I have updated gulp. But still i am getting same error. I have mentioned Gulp version in question. Nov 19, 2019 at 9:33
  • Can you try after downgrading gulp to 3.9.1 band node version to 8.11.3 ?
    – Ravi
    Nov 19, 2019 at 10:43

I assume that you are using NodeJS 12.

The current supported LTS version of NodeJS for the SharePoint Framework is Node.js v8.x and Node.js v10.x (recommended). Node.js v12.x is not currently supported. Notice that Node.js 9.x or 11.x versions are also not supported with SharePoint Framework development.

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.