Disable inkwell click feature in flutter

Viewed 36

Is there a way to disable the InkWell click feature? (I don't want to make it conditional with if and else in onTap, I want it not to be clickable at all).

3 Answers

Simply don't give it an onTap. Leave it out

When you do not pass the onTap function it will be non-clickable,Try this:

InkWell(
   child: Text('click'),
)

Try the following code:

InkWell(
  child: write your code here,
)
Related