Azure Functions training does not respect user's setting of default Node.js version

WayneStewart-0391 0 Reputation points
2024-11-12T21:45:04.3566667+00:00

The "Build Serverless APIs with Azure Functions" training example does not respect the user's setting of default Node.js version via Node Version Manager (nvm):Screenshot 2024-11-12 at 1.12.22 PM

Screenshot 2024-11-12 at 1.17.20 PM

This question is related to the following Learning Module

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
5,179 questions
Azure Training
Azure Training
Azure: A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.Training: Instruction to develop new skills.
1,799 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Bruce (SqlWork.com) 67,906 Reputation points
    2024-11-12T22:18:04.2233333+00:00

    you probably need to set the node version before starting code from the shell.

    0 comments No comments

  2. Ryan Hill 29,131 Reputation points Microsoft Employee
    2024-11-18T21:34:47.3533333+00:00

    Hey @WayneStewart-0391

    Locally, there isn't anything in the tooling to my knowledge that pins a specific node version unless specified in package.json. I advise checking your file to make sure you don't have a version specified there. My guess is something happened when you created the function project against the API project. Another option is creating a separate functions project and copying the /api folder to the new project and adding the missing packages.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.