Docs are confusing for specifying node version and assistance request fo rmy project

" * Add a file named .node-version to the root of your repo. This file contains a single line with the version to use:

18.18.0
  • Add a file named .nvmrc to the root of your repo. This file uses the same format as .node-version."

it says here: Setting Your Node.js Version | Render Docs
so I need both a .node-version and .nvmrc with the exact same thing in them? Or is it one or the other with a preference for .node-version?

My project’s requirements for the environment are like this:

## Requirements

- Node version 16, you can check your node version via `node --version` or install node from https://nodejs.org/en
- Node package manager (NPM) version 8, npm comes bundled with the node installation from https://nodejs.org/en. You can downgrade your npm version if necessary via `npm install -g npm@8`
- Yarn version 1.22, you can check your yarn version via `yarn --version` or install yarn using the node package manager
via `npm install --global yarn`
- Typescript version 5, you can check your typescript version via `tsc --version` or install typescript via `npm install typescript --save-dev`

It is a refactored version of MIT Scratch app that I want to deploy and use privately. Please provide any instructions or advice.

Hi,

The docs you linked show:

Set a different Node.js version in any of the following ways (in descending order of precedence):

So you only need to set one of the ways to set the version.

If you set multiple ways, the order of precedence comes into play.

Alan

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.