1.0.0 • Published 4 years ago

post-message-logger v1.0.0

Weekly downloads
1
License
ISC
Repository
-
Last release
4 years ago

Post Message Logger

This is a mono repo that contains the extension as well as the logger utility.

Usage

This is how you can setup the logger for yourself

import setupLogger from 'post-message-logger'

const iframe = getElementById('my-iframe-window-id');

/**
 * this way the the "incoming" messages will be the ones
 * that come from the iframe and the "outbound" messages will be
 * fired from the current window.
 */
setupLogger(iframe.contentWindow)

once you have setup this, you can find check the post message logger extension when you fire any event.