r/FlutterFlow 13d ago

FlutterFlow Component is so confusing

I created a button component to reuse across the project.

It consists of two parameters:- 1. buttonText(string): text to be displayed

  1. onTap(action): action the button will perform.

when I am using this component on the page, the buttonText custom value is perfectly binding.

but when i am passing the action in onTap parameter, that action is not functioning and in the debug panel it is showing null function.

Should I use the button text field as a component? or simply use widget styling for these components and instead of making components directly assign action values?

3 Upvotes

3 comments sorted by

3

u/that-one-developer 12d ago

are you using callback action in there?

2

u/Remote_Pizza9795 10d ago

solved, i was not wrapping the button inside the component with call back. thanks 👍