Class: WebappMessageReceived

sync.api.Editor.WebappMessageReceived

new WebappMessageReceived(webappMessageJSON, context)

Event triggered when a webapp message is received from the server-side code.

Example of listening for this event:

goog.events.listen(editor, sync.api.Editor.EventTypes.CUSTOM_MESSAGE_RECEIVED, function(e) {
  // e is of type sync.api.Editor.WebappMessageReceived
});
Parameters:
Name Type Description
webappMessageJSON Object The webapp message sent by the server-side code, as JSON.
context string The context in which the message is received.
Source:

Members

(static) Context :string

The constants representing the context in which a webapp message is received.
Type:
  • string
Properties:
Name Type Description
LOAD string During the loading of the document.
SAVE string During the save operation.
SAVE_AS string During the save as operation.
EDITING string While the document is edited.
IMAGE string During a image request.
Source: