import type { Module , ModuleDeclaration } from 'ditox' ; import { bindModule } from 'ditox' ; import React , { ReactElement , ReactNode , useCallback } from 'react' ; import { DependencyContainer , DependencyContainerBinder , } from './DependencyContainer' ; category param params . module param params . scope example export function DependencyModule ( params ) { const { children , module , scope } = params ; const binder = useCallback ( ( container ) => bindModule ( container , module , { scope } ) , [ module , scope ] ) ; return < DependencyContainer binder = { binder } > { children } < /DependencyContainer>; }