0.1.2 • Published 2 years ago

my-modal-maxencec v0.1.2

Weekly downloads
-
License
-
Repository
-
Last release
2 years ago

React Modal

A simple modal build with React

Static Badge

Features

  • Display custom text in a modal
  • Close when clicked outside

Installation

To install, you can use npm or yarn:

$ npm install my-modal-maxencec
$ yarn add my-modal-maxencec

Usage

The component needs two props:

PropsTypesRequiredDefaultDescription
isOpenBooleanIndicates if the modal shoould be open or closed
SetIsOpenFunctionChange isOpen state
textStringText displayed by the modal
import { Modal } from "my-modal-maxencec"
import "my-modal-maxencec/dist/style.css"

function App() {

  return (
    <div className="App">
      <Modal isOpen={modalIsOpen} setIsOpen={setModalIsOpen} text="User created!" />
    </div>
  )
}

export default App

🔗 Links

portfolio linkedin

0.1.2

2 years ago

0.1.1

2 years ago

0.1.0

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago

0.0.0

2 years ago