N
Novu•9mo ago
Cylonik (Tom)

Can you make most recent message pop up so it's visible to the user briefly?

Hi, I'm new to Novu and just added the built in notification inbox. I'm just wondering if it's possible to get it so that certain key messages can popup briefly so the user sees the message without having to go into the notification inbox?
15 Replies
Pawan Jain
Pawan Jain•9mo ago
@Cylonik (Tom) are you using any ui library? It can be achieved using useSocket hook
import { NovuProvider, useSocket, PopoverNotificationCenter, NotificationBell } from "@novu/notification-center";

function Novu() {
return (
<NovuProvider
subscriberId={"SUBSCRIBER_ID"}
applicationIdentifier={"APPLICATION_IDENTIFIER"}
>
<CustomNotificationCenter />
</NovuProvider>
);
}

function CustomNotificationCenter() {
const { socket } = useSocket();

useEffect(() => {
if (socket) {
socket.on("notification_received", (data) => {
console.log(data);
});
}

return () => {
if (socket) {
socket.off("notification_received");
}
};
}, [socket]);

return ( <PopoverNotificationCenter
colorScheme={"dark"}
>
{({ unseenCount }) => <NotificationBell unseenCount={unseenCount} />}
</PopoverNotificationCenter>);
}
import { NovuProvider, useSocket, PopoverNotificationCenter, NotificationBell } from "@novu/notification-center";

function Novu() {
return (
<NovuProvider
subscriberId={"SUBSCRIBER_ID"}
applicationIdentifier={"APPLICATION_IDENTIFIER"}
>
<CustomNotificationCenter />
</NovuProvider>
);
}

function CustomNotificationCenter() {
const { socket } = useSocket();

useEffect(() => {
if (socket) {
socket.on("notification_received", (data) => {
console.log(data);
});
}

return () => {
if (socket) {
socket.off("notification_received");
}
};
}, [socket]);

return ( <PopoverNotificationCenter
colorScheme={"dark"}
>
{({ unseenCount }) => <NotificationBell unseenCount={unseenCount} />}
</PopoverNotificationCenter>);
}
https://docs.novu.co/notification-center/client/react/get-started#toast-notification
Cylonik (Tom)
Cylonik (Tom)•9mo ago
Thanks , very helpful - I made it work
Novu_Bot
Novu_Bot•9mo ago
@Cylonik (Tom), you just advanced to level 1!
Cylonik (Tom)
Cylonik (Tom)•9mo ago
No description
Pawan Jain
Pawan Jain•9mo ago
Awesome 🤩
Cylonik (Tom)
Cylonik (Tom)•9mo ago
Nice library - bit disappointed they just removed the indie dev tier I'm a bootstrapped startup so that seemed very appealing - do you know why it was removed?
Pawan Jain
Pawan Jain•9mo ago
@Tomer Barnea could you help us?
Tomer Barnea
Tomer Barnea•9mo ago
Sure thing @Pawan Jain, my pleasure. @Cylonik (Tom) you are correct and we dropped our indie plan in favor of a much bigger free tier to allow our community members, and early stage to enjoy the product for free in early days and while implementing. @Cylonik (Tom) I am happy to join a call together and see how I can help here, does that sounds good?
Cylonik (Tom)
Cylonik (Tom)•9mo ago
Hi @Tomer Barnea thanks for the explanation. Yes I see a bigger free tier is helpful. My concern is the sudden jump to $250/month as we start to grow. The previous tier allowed gradual growth and up a 100K (double the events) for less (~$170 as I remember) So at 50K events it seems to be almost 3x more expensive now. Appreciate the offer of the call - I might take you up on that in a few days once I've cleared my current backlog. we've done quick proof of concepts in 3 products and this one seems a good fit but it's just jumped to become the most expensive of the 3 once we get some traction
Tomer Barnea
Tomer Barnea•9mo ago
got it@Cylonik (Tom), thanks for letting us know that. We would love to help you there and make sure it makes sense to both of us, and we surely don't want you to reimplement that. @Cylonik (Tom) let me know when would be the right time, and let's join this call, I am sure we can solve this. cc @Ryan Reynolds @justnems
Cylonik (Tom)
Cylonik (Tom)•9mo ago
Thanks both - and appreciate you taking the time to explain and listen. I'll get back to you soon to schedule a call. have a great day.
Tomer Barnea
Tomer Barnea•9mo ago
🙂
Cylonik (Tom)
Cylonik (Tom)•9mo ago
Hi @Tomer Barnea Would a call today be possible to discuss options? Thanks.
Tomer Barnea
Tomer Barnea•9mo ago
Hey @Cylonik (Tom) I sent you a DM
Want results from more Discord servers?
Add your server