Coder Social home page Coder Social logo

numandev1 / react-native-usemarkdown-chat Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 1.01 MB

hook for chats markdown in Textinput

Home Page: https://614db906865efbc908490c6f--react-native-usemarkdown-chat-hook.netlify.app/

License: MIT License

JavaScript 33.81% TypeScript 41.96% HTML 24.24%
markdown chat hook bold italc underline markdown-editor editor

react-native-usemarkdown-chat's Introduction

alt text

use bold, italic and underline markdown for chat while typing

Installation

npm install react-native-usemarkdown-chat

Usage

import useMarkdown, { textToMarkdown } from 'react-native-usemarkdown-chat';

// ...

const [text, setText] = useMarkdown();

textToMarkdown function is not hook it is basically text to markdown converter. you can use this for making own custom useState.

Example Code

import * as React from 'react';

import { StyleSheet, View, TextInput } from 'react-native';
import useMarkdown from 'react-native-usemarkdown-chat';

export default function App() {
  const [text, setText] = useMarkdown();
  return (
    <View style={styles.container}>
      <TextInput style={styles.input} value={text} onChangeText={setText} />
    </View>
  );
}

const styles = StyleSheet.create({
  container: {
    flex: 1,
    alignItems: 'center',
    justifyContent: 'center',
  },
  input: {
    width: '100%',
    height: 100,
    backgroundColor: 'gray',
    fontSize: 30,
  },
});

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT

react-native-usemarkdown-chat's People

Contributors

numandev1 avatar

Stargazers

 avatar

Watchers

 avatar  avatar

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.