I am looping Text Field hundreds times
for (var i = 0; i < 100; i++)
my label Text is look like this labelText: '${i + 1}',
I want to set Condition if i is below 10 then add extra 0 before number
I did try with like this
'${i < 10 ? "0"i + 1 : i + 1}',
getting error Expected to Find '}'

for (var i = 0; i < 100; i++) print(i.toString().padLeft(2, '0'));or in your case:labelText: i.toString().padLeft(2, '0')labelText: (i + 1).toString().padLeft(2, '0')