LiteMol icon indicating copy to clipboard operation
LiteMol copied to clipboard

How to listen to event 'loaded'?

Open tschaka1904 opened this issue 8 years ago • 1 comments

Is there an event, which tells me if the viewer has been fully loaded? If so, how do I use it?

tschaka1904 avatar Feb 07 '17 14:02 tschaka1904

If you mean the plugin, calling Plugin.create() is a synchronous and should be called after the DOM element that should contain the plugin has been loaded using standard practices.

If you mean loading a molecule, the plugin.applyTransform function returns a Promise and can be used for example like this or using async/await.

EDIT: and if you mean the PDB Component Library plugin, best place would be to ask Mandar Deshpande in Hinxton.

dsehnal avatar Feb 07 '17 14:02 dsehnal