1.0.1 • Published 4 months ago

button-knighthunt v1.0.1

Weekly downloads
-
License
ISC
Repository
gitlab
Last release
4 months ago

Custom Button Component

A simple React component for creating customizable buttons.

Installation

npm install my-custom-button

Usage

import React from 'react';
import Button from 'my-custom-button';

const MyComponent = () => {
  return (
    <div>
      <Button primary onClick={() => console.log('Primary button clicked')}>
        Primary Button
      </Button>
      <Button onClick={() => console.log('Secondary button clicked')}>
        Secondary Button
      </Button>
    </div>
  );
};

export default MyComponent;

Props

  • primary (optional): Set to true for a primary button with a blue background.
  • onClick (optional): Callback function to be executed when the button is clicked.

Styles

The button has a default style, but you can customize it further by passing additional styles or modifying the existing ones.

License

This project is licensed under the ISC License.

1.0.1

4 months ago

1.0.0

4 months ago