1.0.2 • Published 3 years ago

react-ninja-message v1.0.2

Weekly downloads
6
License
ISC
Repository
-
Last release
3 years ago

react-ninja-message

react-ninja-message is a react base component that with zero dependencies, That add animated ninja with your custom message to display.

codesandbox demo -> Demo

Installation

Use the package manager npm to install .

npm i react-ninja-message 

Usage

import React from "react";
import { NinjaMessage } from "react-ninja-message";

export default function App() {
  return (
    <div className="App">
      <h1>react-ninja-message</h1>
        <NinjaMessage color="#32e4ec" message="looking for ninja ?"/>,
    </div>
  );
}
propstypedefault valueinfo
messagestring'hi !'Text message to display
messageTimeMsnumber10000Delay until message disappear
logoSrcstring'https://upload.wikimedia.org/wikipedia/commons/a/a7/React-icon.svg'Path to logo image (50x50)
logoRenderanyundefineduse to render custom logo (limit to 50x50 container). Using this props overwrite logoSrc props
colorstring'red'Set the ninja ribbon color
pClassNamestringundefinedAdvance options for replace all default style.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT