Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@mxenabled/widget-post-message-definitions

Package Overview
Dependencies
Maintainers
23
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mxenabled/widget-post-message-definitions

Widget Post Message Definitions for use in SDKs

  • 1.4.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2.4K
decreased by-27.79%
Maintainers
23
Weekly downloads
 
Created
Source

Widget Post Message Definitions for TypeScript

Overview

This project defines and implements all Post Message parsing and dispatching in TypeScript. This is for use in Widget SDKs. The majority of this package was auto generated by the Widget Post Message Definitions project, and any modifications to a Post Message definition or handling should be done there.

Getting started

You can install this package via npm:

npm install --save @mxenabled/widget-post-message-definitions
import { dispatchConnectLocationChangeEvent } from "@mxenabled/widget-post-message-definitions"

dispatchConnectLocationChangeEvent("mx://connect/memberDeleted?metadata=...", {
  onMemberDeleted: (payload) => {
    console.log(`${payload.member_guid} has been deleted`)
  }
})

Dependencies

This package does not have any dependencies with the exception of the url package, which you may need if you're parsing post message events from URL change events.

The React Native SDK needs this package and has it as a dependency, but the Web SDK won't and we shouldn't install or import it. This allows us to keep both SDKs happy.

To install url in your project so you can parse post messages in location change events:

npm install --save url

FAQs

Package last updated on 04 Mar 2024

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