how to add onpressed to a text flutter

108

new GestureDetector(
  onTap: () {
    Navigator.pushNamed(context, "myRoute");
  },
  child: new Text("my Title"),
);

Comments

Submit
0 Comments