Skip to content

Stacked mode. Mobile. After being closed, notifications does not stack again. #1268

@JustinasAltaravicius

Description

@JustinasAltaravicius

Vid:

Screen.Recording.2025-11-20.at.11.05.48.mov

Code:

layout.tsx

import { ToastBtn } from "./ToastBtn";

export default function RootLayout() {
  return (
    <html lang="en">
      <body>
        <ToastBtn />
      </body>
    </html>
  );
}

ToastBtn.tsx


import { ToastContainer, toast } from "react-toastify";

export const ToastBtn = () => {
  const notify = () => toast("Wow so easy !");

  return (
    <div className="grid place-items-center h-dvh bg-zinc-900/15">
      <button onClick={notify}>Notify !</button>
      <ToastContainer stacked position="bottom-center" />
    </div>
  );
};

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions