Issue with importing serve function
I'm trying to follow this guide: https://docs.novu.co/echo/concepts/endpoint
and this is broken:
import { EchoRequestHandler, ServeHandlerOptions } from '@novu/echo';
Those aren't exported from the package
4 Replies
Hi @KaisSalha, I'm an AI assistant for Novu. While a team member reviews this question, I'll see if I can find relevant sources for your question.
-----------------------------
While I generate an answer, here are some sources that might be helpful:
* Integrate Novu with Nuxt
* Integrate Novu with Next.js
* Introduction
* Quick Start
-----------------------------
Answer
It appears that the imports
EchoRequestHandler
and ServeHandlerOptions
you are trying to use are not directly mentioned in the provided documentation extracts. However, the correct import for the serve
function from the @novu/echo
package should look like this:
(1) , (2)
These snippets show how to properly use the serve
function within Nuxt.js and Next.js frameworks respectively.
If EchoRequestHandler
and ServeHandlerOptions
are not being found, it's possible they might not be exported or could be part of a different version or package. Please ensure you are using the correct version of the package that supports these exports, or check the latest documentation or the repository for any recent changes that might have deprecated or moved these exports.I'm intergrating it with Fastify so I'll have to go the manual route.
I'm on the latest available version:
"@novu/echo": "0.24.3-alpha.0",
@KaisSalha
Thanks for sharing. We are working on fix