MiniProgramScope constructor
const
MiniProgramScope({
- Key? key,
- required Widget child,
- MiniProgramConfig? config,
- MiniProgramController? controller,
- bool disposeController = false,
Implementation
const MiniProgramScope({
super.key,
required this.child,
this.config,
this.controller,
this.disposeController = false,
this.navigationDelegate,
}) : assert(
config != null || controller != null,
'MiniProgramScope requires either config or controller.',
),
assert(
config == null || controller == null,
'MiniProgramScope accepts either config or controller, not both.',
),
assert(
controller == null || navigationDelegate == null,
'Pass navigationDelegate to MiniProgramController when injecting a controller.',
),
assert(
controller != null || !disposeController,
'disposeController only applies when controller is injected.',
);