1.0.14 • Published 2 years ago

videorepute-chat-interview v1.0.14

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

Live Demo

šŸ”— gh pages

videorepute-chat-interview

A simple and efficient npm package for integrating a chatbot into your application, designed specifically for VideoRepute interview preparation.

Prerequisites

Before installing this package, please ensure that you have React version 18.2 or higher installed in your project.

Installation

You can install this package via npm:

npm install videorepute-chat-interview

Usage

import { Chat } from "videorepute-chat-interview";
import logo from "./assets/images/logo.svg";

function App() {
  // Define functions to save and clear messages in local storage
  const saveMessage = (messages: messageType[]) => {
    localStorage.setItem("dataMessage", JSON.stringify(messages));
  };

  const clearMessage = () => {
    localStorage.removeItem("dataMessage");
  };

  return (
    <Chat
      greetingMessage="Hello! Welcome to the interview chatbot."
      logo={logo}
      clear={clearMessage}
      onChange={saveMessage}
      dir="rtl"
    />
  );
}

export default App;

Props

  • greetingMessage: The initial message displayed by the chatbot.
  • image displayed in the chatbot.
  • clear: Function to clear messages from local storage.
  • onChange: Function called when messages are updated.
  • dir: Text direction (rtl or ltr).
1.0.2

2 years ago

1.0.1

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.11

2 years ago

1.0.10

2 years ago

1.0.14

2 years ago

1.0.13

2 years ago

1.0.12

2 years ago

1.0.0

2 years ago

0.0.1

2 years ago