Remove context(parentNode: Node) and provide the parent Node as a parameter.
This commit is contained in:
parent
f1822c5afd
commit
07b6148035
161 changed files with 668 additions and 436 deletions
|
|
@ -6,8 +6,11 @@ import com.bumble.appyx.core.plugin.Plugin
|
|||
import io.element.android.libraries.architecture.FeatureEntryPoint
|
||||
|
||||
interface ${FEATURE_NAME}EntryPoint : FeatureEntryPoint {
|
||||
context(parentNode: Node)
|
||||
fun createNode(buildContext: BuildContext, callback: Callback): Node
|
||||
fun createNode(
|
||||
parentNode: Node,
|
||||
buildContext: BuildContext,
|
||||
callback: Callback,
|
||||
): Node
|
||||
|
||||
interface Callback : Plugin {
|
||||
// Add your callbacks
|
||||
|
|
|
|||
|
|
@ -10,8 +10,12 @@ import dev.zacsweers.metro.AppScope
|
|||
|
||||
@ContributesBinding(AppScope::class)
|
||||
class Default${FEATURE_NAME}EntryPoint() : ${FEATURE_NAME}EntryPoint {
|
||||
context(parentNode: Node)
|
||||
override fun createNode(buildContext: BuildContext, callback: ${FEATURE_NAME}EntryPoint.Callback): Node {
|
||||
|
||||
override fun createNode(
|
||||
parentNode: Node,
|
||||
buildContext: BuildContext,
|
||||
callback: ${FEATURE_NAME}EntryPoint.Callback,
|
||||
): Node {
|
||||
return parentNode.createNode<${FEATURE_NAME}FlowNode>(buildContext, listOf(callback))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue