Is there a way with NumberFormat to display :
NumberFormat
Thanks for yo
Maybe you don't want use NumberFormat:
class DoubleToString { String format(double toFormat) { return (toFormat * 10) % 10 != 0 ? '$toFormat' : '${toFormat.toInt()}'; } }