I retrieve a piece of text from an API. I want to allot a set amount of space to it (say a max Container with width: 300.0 and height: 100.0). Sometimes, the piece of text fits
Here is a list of things I tried which may work for you depending on your use case: https://github.com/flutter/flutter/issues/18431
Ultimately I went with a function that sets the font size based on the length of the String (i.e. with if-else statements).