The comunication between host and basket is based on browser message events (see window.postMessage()
).
The basket will send messages to the host by calling postMessage on its opener window if it is running in an own window/tab or on its parent if it is running in an iframe.
To send a message to the basket, postMessage has to be called on its window. If it is running in an iframe the iframe's contentWindow has to be used.
The actual data/message is stored in the data of the message event. Further information about the structure of the data and the available messages can be found in the typescript definitions (which are also part of this documentation) for the message API.
Generated using TypeDoc