New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@breedr/messaging

Package Overview
Dependencies
Maintainers
6
Versions
139
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@breedr/messaging

[![npm version](https://badge.fury.io/js/%40breedr%2Fmessaging.svg)](https://badge.fury.io/js/%40breedr%2Fmessaging)

  • 1.7.25
  • unpublished
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
6
Weekly downloads
 
Created
Source

Breedr Messaging

npm version

Installation

To install the latest version run:

yarn add @breedr/messaging

or

npm install --save @breedr/messaging

Usage

initMessaging()

It is a Promise function to initialize Breedr Messaging .

await initMessaging({
  userInfo, // backend `User` type, result of `userInfo` query
  apolloClient,
  appId: env.SEND_BIRD_APP_ID,
})

It makes the Messaging context available to the rest of your app: .

render() {
  return (
    <Provider store={store}>
      <ApolloProvider client={apolloClient}>
        <MessagingProvider>
          <App />
        </MessagingProvider>
      </ApolloProvider>
    </Provider>
  );
}

connectMessaging()

It is a HOC to connect your component to the Messaging context. .

export default compose(
  connectMessaging((messaging) => ({
    channels: messaging.getGroupChannels(),
    unreadMessagesCount: messaging.getUnreadGroupMessagesCount(),
    refresh: messaging.refreshChannels,
  })),
  lifecycle({
    componentDidMount() {
      this.props.refresh();
    },
  }),
)(Channels);

FAQs

Package last updated on 23 Dec 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc