DEV Community

Jon Friesen
Jon Friesen

Posted on • Originally published at jonfriesen.ca on

App Platform: How to set specific NodeJS version?

NodeJS projects have an optional configuration in their package.json for indicating the supported engine(s) for an app. This can look like:

{ 
  "engines" : { 
    "node" : "12.19.0" 
  }
}

Enter fullscreen mode Exit fullscreen mode

ranges are also supported, for example:

{ 
  "engines" : { 
    "node" : ">=12.0.0 <=14.0.0" 
  }
}

Enter fullscreen mode Exit fullscreen mode

this range says an app can be run on NodeJS 12 to 14 (inclusively).

Click here for more info on NoedJS engines.

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay