Skip to content

Error: A value of type 'RenderObject?' can't be assigned to a variable of type 'AbstractNode?'. #8

@GlennMm

Description

@GlennMm

Got the following error when i imported this crud_table package into my project

ERROR: ../../../.pub-cache/hosted/pub.dev/fluid_kit-2.1.0/lib/src/fluidable.dart:48:55: Error: A value of type 'RenderObject?' can't be assigned to a variable of type 'AbstractNode?'.
ERROR: - 'RenderObject' is from 'package:flutter/src/rendering/object.dart' ('../../../frameworks/flutter/packages/flutter/lib/src/rendering/object.dart').
ERROR: - 'AbstractNode' is from 'package:flutter/src/foundation/node.dart' ('../../../frameworks/flutter/packages/flutter/lib/src/foundation/node.dart').
ERROR: final AbstractNode? targetParent = renderObject.parent;
ERROR: ^
ERROR: ../../../.pub-cache/hosted/pub.dev/fluid_kit-2.1.0/lib/src/fluidable.dart:49:54: Error: The method 'markNeedsLayout' isn't defined for the class 'AbstractNode?'.
ERROR: - 'AbstractNode' is from 'package:flutter/src/foundation/node.dart' ('../../../frameworks/flutter/packages/flutter/lib/src/foundation/node.dart').
ERROR: Try correcting the name to the name of an existing method, or defining a method named 'markNeedsLayout'.
ERROR: if (targetParent is RenderObject) targetParent.markNeedsLayout();
ERROR: ^^^^^^^^^^^^^^^
ERROR: Target kernel_snapshot failed: Exception
Error: Build process failed
swappy-20240605_222614

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions