I wanna put a default value on a textfield if _contact is not null. To do this
new TextField(
decoration: new InputDecoration(labelText: "Email"),
maxLines: 1,
controller: new TextEditingController(text: (_contact != null) ? _contact.email: ""))
Is there a better way to do that? E.g: Javascript would be something like: text: _contact ? _contact.email : ""