API reference
new MobbSign(options)
Creates the viewer and renders it in options.root. Returns a Promise that resolves to the configured instance. The options are described in Configuration.
- Correct
- Incorrect
new MobbSign(options).then((mobbsign) => mobbsign.load(documentId));
// The constructor returns a promise, not the instance
const mobbsign = new MobbSign(options);
mobbsign.load(documentId);
load(documentId)
Loads a document of MobbSign Server in the viewer.
| Parameter | Type | Description |
|---|---|---|
documentId | string | Identifier of the document in MobbSign Server. |
Returns a Promise that resolves when the document has been loaded. Wait for it before loading another document:
- Correct
- Incorrect
mobbsign.load(firstId).then(() => mobbsign.load(secondId));
mobbsign.load(firstId);
mobbsign.load(secondId);