Coder Social home page Coder Social logo

cinaaaa / react-tagify Goto Github PK

View Code? Open in Web Editor NEW
27.0 0.0 4.0 790 KB

✨ Empower React applications with effortless #tag and @mention support

Home Page: https://react-tagify-site.vercel.app

License: MIT License

JavaScript 14.14% TypeScript 70.04% HTML 2.79% CSS 13.02%
react hashtags mentions highlight highlighting react-tagify tagify component

react-tagify's Introduction

React Tagify Promo Tweet

✨ React Tagify #️@

Empower your React applications with effortless #tag and @mention support ❤️

React Tagify is a powerful and pure React component for handling hashtags and mentions in your React app with ease. Give your users the ability to mention others and add tags to their content seamlessly.

For more information and demo, visit our website here.

Features

  • 🚀 Easy to integrate
  • 🎨 Customizable colors and styles
  • 🔗 Supports #HashTags and @Mentions
  • 📦 Lightweight

Installation

Install the package using npm or yarn:

npm i react-tagify

or

yarn add react-tagify

Usage

  1. Import the Tagify component:
import { Tagify } from 'react-tagify';
  1. Wrap your content with the Tagify component:
<Tagify
  onClick={(text, type) => console.log(text, type)}
>
  <p>
    This is a #React component with help of #ReactTagify!
  </p>
</Tagify>

Props

Prop Type Default Description
children ReactNode - The content to be processed for tags and mentions.
color string '#0073e6' The color of the tags and mentions.
onClick function - A callback function that is called when a tag or mention is clicked. Receives the clicked element as an argument and type of it
tagStyle object - The CSS style object for hashtag styling.
mentionStyle object - The CSS style object for mention styling.
detectHashtags boolean true Enable or disable the detection of hashtags.
detectMentions boolean true Enable or disable the detection of mentions.

Contributing

Please feel free to contribute by submitting a pull request or reporting any issues you encounter while using this component.

License

React Tagify is licensed under the MIT License.

react-tagify's People

Contributors

cinaaaa avatar dependabot[bot] avatar johnanisere avatar theashraf avatar viveknaragude avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

react-tagify's Issues

Tests for new Link Feature

Is your feature request related to a problem? Please describe.
We Have New Feature for Detecting Links in our component and we dont have tests for it

Describe the solution you'd like
similar test like other for this.

Hover functionality for hashtag and mention

Hi Sina, hope you are doing well and thanks for the awesome library.

Currently Hashtags and mentions are clickable. it that possible for you to add Hover functionality for those?
I need to show a popup for mentions.

thanks in advance.

Writing Test for Code's

Is your feature request related to a problem? Please describe.
I Need Good and Clear Testing Code for Our Project
You'r All Welcome

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.