Open Sokratesli opened 1 year ago
Even I'm getting the same error.
Hi @Sokratesli @shivpratik Can you please share with me the steps to reproduce it?
Hi @shubhamUpadhyayInBlue have the same issue even though I have installed brevo package and followed the steps written in Readme about instalation I have problem with connect API
"I am also facing this problem - error ./node_modules/@getbrevo/brevo/src/index.js Module not found: Can't resolve 'ApiClient' Did you mean './ApiClient'? Requests that should resolve in the current directory need to start with './'. Requests that start with a name are treated as module requests and resolve within module directories (node_modules, /Users/angelo/Documents/APP_DEV/nextjs/gestyon-stok). If changing the source code is not an option, there is also a resolve option called 'preferRelative' which tries to resolve these types of requests in the current directory too."
The problem seems to be that the tool I'm using to compile my Next.js code (https://swc.rs/) supports AMD modules. However, in the brevo-node documentation, specifically in the "Webpack Configuration" section
, it specifies to disable AMD modules. Therefore, the simplest solution is to use their API without any additional installation using fetch, for example. In my case, I'm using:
I want to clarify that I'm using the node-fetch package (https://www.npmjs.com/package/node-fetch) on the server side.
Hi @Sokratesli @shivpratik Can you please share with me the steps to reproduce it?
Hi @shubhamUpadhyayInBlue, I'm getting this error when trying to import "@getbrevo/brevo" in files apart from the main API file. Example: I wanted to have all my email and sms functions in a separate file and when I try to import "@getbrevo/brevo" in that file I get this error. This error doesn't occur when used in API handler file.
When i install @getbrevo/brevo
from npm it's working as expected in my vite react app and node app. but not able to run the package from local for react project. In my case the issue didn't occurs. Can you share the steps to reproduce.
Same issue here. The project used sib before and after upgrade to @getbrevo/brevo.
Hello, It's because the dependencies are not installed correctly. Running an npm install
fixed it.
I have a nextjs application and now i am trying to implement brevo. but it keeps showing me this error:
Thanks for the help.
Reproduce:
import SendEmail from ./send-email
send-email.js