Type Definition rusty_v8::HostInitializeImportMetaObjectCallback[][src]

type HostInitializeImportMetaObjectCallback = extern "C" fn(_: Local<'_, Context>, _: Local<'_, Module>, _: Local<'_, Object>);
Expand description

HostInitializeImportMetaObjectCallback is called the first time import.meta is accessed for a module. Subsequent access will reuse the same value.

The method combines two implementation-defined abstract operations into one: HostGetImportMetaProperties and HostFinalizeImportMeta.

The embedder should use v8::Object::CreateDataProperty to add properties on the meta object.