I have an Angular project and doing the deploy of my function gives me this error:
! functions [sendEmailConfirmation]: Deployment error. Function load error: Code in file index.js can not be loaded. Did you list all required modules in the package.json dependencies? Detailed stack trace: Error: Can not find module 'nodemailer'
I made npm install nodemailer and I have it in my dependencies of the package.json:
"nodemailer": "^4.6.4",
"firebase": "^4.12.0",
"firebase-admin": "^5.12.0",
My index.js:
const nodemailer = require('nodemailer');