pub struct ModuleLoaderHooks {
pub normalize: ModuleNormalizeFunc,
pub loader: ModuleLoaderFunc,
pub loader2: ModuleLoaderFunc2,
pub check_attrs: ModuleCheckAttrs,
pub opaque: *mut c_void,
}Expand description
What JS_SetModuleLoaderFunc/JS_SetModuleLoaderFunc2 installed.
Kept on the runtime rather than pushed into a context, because the reference’s signature
takes a JSRuntime * and a context created later has to inherit it.
Fields§
§normalize: ModuleNormalizeFuncJSModuleNormalizeFunc.
loader: ModuleLoaderFuncJSModuleLoaderFunc — the one-argument form.
loader2: ModuleLoaderFunc2JSModuleLoaderFunc2, the form that also receives the import attributes.
check_attrs: ModuleCheckAttrsJSModuleCheckSupportedImportAttributes.
opaque: *mut c_voidThe host’s context pointer.
Trait Implementations§
Source§impl Clone for ModuleLoaderHooks
impl Clone for ModuleLoaderHooks
impl Copy for ModuleLoaderHooks
Auto Trait Implementations§
impl !Send for ModuleLoaderHooks
impl !Sync for ModuleLoaderHooks
impl Forget for ModuleLoaderHooks
impl Freeze for ModuleLoaderHooks
impl Move for ModuleLoaderHooks
impl RefUnwindSafe for ModuleLoaderHooks
impl Unpin for ModuleLoaderHooks
impl UnsafeUnpin for ModuleLoaderHooks
impl UnwindSafe for ModuleLoaderHooks
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more