@hookeasy/use-notification

1.0.1 • Public • Published

@hookeasy/use-notification

React Hook to update your notification event

install

npm i @hookeasy/use-notification

or

yarn add @hookeasy/use-notification

example

import React, { useEffect } from "react";
import ReactDOM from "react-dom";
import useNotification from "@hookeasy/use-notification";

const App = () => {
  const triggerNotif = useNotification("hello guys", {
    body: "goood!!"
  });
  return (
    <div className="App">
      <button onClick={triggerNotif}>Hello</button>
    </div>
  );
};

const rootElement = document.getElementById("root");
ReactDOM.render(<App />, rootElement);

Package Sidebar

Install

npm i @hookeasy/use-notification

Weekly Downloads

0

Version

1.0.1

License

MIT

Unpacked Size

3.07 kB

Total Files

5

Last publish

Collaborators

  • baram