Gathering detailed insights and metrics for manoshatzi-pubnub-react-chat-components
Gathering detailed insights and metrics for manoshatzi-pubnub-react-chat-components
Chat UI Components to build chat applications with PubNub on React with TypeScript support
npm install manoshatzi-pubnub-react-chat-components
Typescript
Module System
Node Version
NPM Version
TypeScript (73.87%)
SCSS (22.21%)
JavaScript (2.86%)
HTML (0.93%)
Shell (0.1%)
CSS (0.03%)
Love this project? Help keep it running — sponsor us today! 🚀
Total Downloads
1,369
Last Day
4
Last Week
7
Last Month
35
Last Year
151
199 Commits
1 Watching
6 Branches
1 Contributors
Minified
Minified + Gzipped
Latest Version
0.7.6
Package Id
manoshatzi-pubnub-react-chat-components@0.7.6
Unpacked Size
2.02 MB
Size
388.66 kB
File Count
32
NPM Version
8.1.3
Node Version
14.18.1
Cumulative downloads
Total Downloads
Last day
0%
4
Compared to previous day
Last week
-12.5%
7
Compared to previous week
Last month
218.2%
35
Compared to previous month
Last year
-9.6%
151
Compared to previous year
4
32
PubNub Chat Components for React are the fastest way to add chat features like direct and group messaging, typing indicators, reactions, without going through the complexity of low-level architecture of realtime networks.
Set up and use PubNub Chat Components for React to build your own chat application.
Sign in or create an account to create an app on the Admin Portal and get the keys to use in your application.
When you create a new app, the first set of keys is generated automatically, but a single app can have as many keysets as you like. We recommend that you create separate keysets for production and test environments.
Some of the functionalities you might want to enable on your keyset depending on the use-case include Presence, Files, Storage & Playback (including correct Retention Period) and Objects (be sure to select a geographical region corresponding to most users of your application and to enable User, Channel and Membership Events). The moderated-chat sample requires these features are set in order to work with the moderation dashboard.
Start by exploring our Sample Apps that are built using chat components. Follow the steps below to run the apps locally in your own environment.
1git clone https://github.com/pubnub/react-chat-components.git
samples
folder.1cd react-chat-components/samples
1npm install
.env.example
file as .env
and paste your keys there.1cp .env.example .env 2vi .env
1npm run setup
1npm start
1npm install --save pubnub pubnub-react @pubnub/react-chat-components
1import PubNub from "pubnub"; 2import { PubNubProvider } from "pubnub-react"; 3import { 4 Chat, 5 MessageList, 6 MessageInput, 7 ChannelList, 8 MemberList, 9} from "@pubnub/react-chat-components";
1const pubnub = new PubNub({ 2 publishKey: "myPublishKey", 3 subscribeKey: "mySubscribeKey", 4 uuid: "myUniqueUUID", 5}); 6const currentChannel = "myCurrentChannel"; 7const theme = "light";
1const MyComponent = () => { 2 return <PubNubProvider client={pubnub}></PubNubProvider>; 3};
1const MyComponent = () => { 2 return ( 3 <PubNubProvider client={pubnub}> 4 <Chat {...{ currentChannel, theme }}> 5 <MessageList /> 6 <MessageInput /> 7 </Chat> 8 </PubNubProvider> 9 ); 10};
No vulnerabilities found.
No security vulnerabilities found.