0.1.2 • Published 3 years ago

my-modal-maxencec v0.1.2

Weekly downloads
-
License
-
Repository
-
Last release
3 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

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago

0.0.0

3 years ago