1.0.1 • Published 11 months ago

@dancingparakeet/word-weaver v1.0.1

Weekly downloads
-
License
-
Repository
-
Last release
11 months ago

Word Weaver

npm version License: MIT React

A minimal React component to generate cool names for demo projects, throwaway accounts, containers, and anything really!

Installation

npm install @dancingparakeet/word-weaver
# or
yarn add @dancingparakeet/word-weaver

Usage Example

import React from 'react';
import WordWeaver from '@dancingparakeey/word-weaver';

const CustomWordGenerator = () => {
    const customGenerate = () => {
        // Custom word generation logic
        console.log('Custom generate logic called');
    };

    const handleCustomWordGenerated = (word) => {
        console.log('Custom generated word:', word);
    };

    return (
        <div>
            <h2>Custom Word Generator</h2>
            <WordWeaver generate={customGenerate} onWordGenerated={handleCustomWordGenerated} />
        </div>
    );
};

export default CustomWordGenerator;

Props

PropTypeDescription
generate() => voidOptional custom function to generate a word
onWordGenerated() => voidCallback function called with the generated word

Author

Made with 💖 by dancingparakeet

GitHub: @dancingparakeet

License

This project is licensed under the MIT License Feel free to use this code wherever you'd like

1.0.1

11 months ago

1.0.0

11 months ago