All Projects → cawfree → react-native-twitter-textview

cawfree / react-native-twitter-textview

Licence: MIT license
A <TextView/> component for React Native built on top of twitter-text linkification.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to react-native-twitter-textview

Dzhtmltext
Delphi and Lazarus HTML Label component
Stars: ✭ 60 (-15.49%)
Mutual labels:  tags, link
remark-external-links
Legacy plugin to automatically add target and rel attributes to external links — please use `rehype-external-links` instead
Stars: ✭ 50 (-29.58%)
Mutual labels:  link
additional tags
Redmine Plugin for adding tags functionality to issues and wiki pages.
Stars: ✭ 25 (-64.79%)
Mutual labels:  tags
ember-link-action
Fire an action when LinkTo component transition happens
Stars: ✭ 86 (+21.13%)
Mutual labels:  link
yogurl
Serve files and code over HTTP in one command. The CLI for http://yogurl.io
Stars: ✭ 45 (-36.62%)
Mutual labels:  link
react-native-element-textinput
A react-native TextInput, TagsInput and AutoComplete component easy to customize for both iOS and Android.
Stars: ✭ 28 (-60.56%)
Mutual labels:  tags
browser-resources
A Collection of official Resources/Status/Issues for browsers.
Stars: ✭ 127 (+78.87%)
Mutual labels:  link
instastory.js
This is a jQuery plugin to make it easy to get a feed from instagram. No need of access tokens and other stuff, Only thing needed is jQuery.
Stars: ✭ 36 (-49.3%)
Mutual labels:  hashtags
github-tags
给Github项目添加标签的Chrome插件,支持按标签搜索,支持数据云同步
Stars: ✭ 34 (-52.11%)
Mutual labels:  tags
adversaria
Typeclass interfaces to access user-defined Scala annotations
Stars: ✭ 22 (-69.01%)
Mutual labels:  tags
svg-tag-mode
A minor mode for Emacs that replace keywords with nice SVG labels
Stars: ✭ 314 (+342.25%)
Mutual labels:  tags
material-chip-view
Material Chip view. Can be used as tags for categories, contacts or creating text clouds
Stars: ✭ 1,300 (+1730.99%)
Mutual labels:  tags
phppimaco
Biblioteca para geração de Etiquetas PIMACO
Stars: ✭ 61 (-14.08%)
Mutual labels:  tags
bootstrap5-tags
Replace select[multiple] with nices badges for Bootstrap 5
Stars: ✭ 58 (-18.31%)
Mutual labels:  tags
audio-tag-analyzer
Extracts metadata music metadata found in audio files
Stars: ✭ 18 (-74.65%)
Mutual labels:  tags
FlowLayout
Android流式布局实现热门标签效果
Stars: ✭ 65 (-8.45%)
Mutual labels:  tags
Socially
Socially is a textView which is able to create separate clickable views according to your requirements.
Stars: ✭ 28 (-60.56%)
Mutual labels:  mention
tags
HTML tags in Go
Stars: ✭ 50 (-29.58%)
Mutual labels:  tags
EEStackLayout
A structured vertical/horizontal stack layout
Stars: ✭ 48 (-32.39%)
Mutual labels:  tags
URL-Shortner-Bot-V2
A link shortner telegram bot version 2 with advanced features
Stars: ✭ 18 (-74.65%)
Mutual labels:  link

react-native-twitter-textview

A <Text/> component for React Native and React Native Web that automatically detects #hashtags and @mentions.

code style: prettier

🚀 Getting Started

Using npm:

npm install --save react-native-twitter-textview

Using yarn:

yarn add react-native-twitter-textview

✍️ Usage

It's super easy; just replace your React Native <Text /> component with a <TwitterTextView />, and there you go!

const App = () => {
  const [value, onChangeText] = useState('');
  return (
    <View
      style={StyleSheet.absoluteFill}
    >
      <TextInput
        onChangeText={onChangeText}
        value={value}
        placeholder="Type some #hashtags or @mentions to get started."
        multiline
        numberOfLines={4}
      />
      <TwitterTextView
        style={styles.twitterTextView}
        hashtagStyle={styles.hashtagStyle}
        mentionStyle={styles.mentionStyle}
        linkStyle={styles.linkStyle}
        emailStyle={styles.emailStyle}
      >
        {value}
      </TwitterTextView>
    </View>
  );
}

✍️ Input

Are you looking for a similar component for tagged <TextInput/>? If so, please check out react-native-segmented-text-input.

📋 Props


Prop Type Default Required Description
children string '' No The text to render.
extractHashtags bool true No Whether you wish to support hashtags.
onPressHashtag func (e, hashtag) => null No Called when a detected hashtag is clicked.
hashtagStyle shape[object Object] styles.linkStyle No Hashtag style.
extractMentions bool true No Whether you wish to support mentions.
onPressMention func (e, hashtag) => null No Called when a detected mention is clicked.
mentionStyle shape[object Object] styles.linkStyle No Mention style.
extractLinks bool true No Whether you wish to support links.
onPressLink func (e, link) => Linking.openURL(link) No Called when a detected link is clicked.
linkStyle shape[object Object] styles.linkStyle No Link style.
extractEmails bool true No Whether you wish to support emails.
onPressEmail func (e, link) => Linking.openURL(link) No Called when a detected email is clicked.
emailStyle shape[object Object] styles.linkStyle No Email style.

✌️ License

MIT

Buy @cawfree a coffee

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].