unregisterModel

@vulp/js-api > VulpApi > unregisterModel

VulpApi.unregisterModel() method

Disconnects an iframe containing a Vulp model. Can be called to free up resources when a model is no longer needed.

Signature:

static unregisterModel(iframe: HTMLIFrameElement | null): Promise<void>;

Parameters

ParameterTypeDescription
iframeHTMLIFrameElement | nullThe iframe element containg the Vulp model.

Returns:

Promise<void>

Example

const iframe = document.querySelector('iframe');
const model = VulpApi.unregisterModel(iframe);