I am using xcode(v13.4.1
) to build a flutter app, when I first build the app, shows error like this:
This application cannot tree shake icons fonts. It has non-constant instances of IconData at the following locations:
but did not work, am I missing something? what should I do to fixed this problem?
CodePudding user response:
You should be able to set a flag within the User-defined
variables in Xcode in order to disable tree shaking icons.
- Select the top most
Runner
in the left pane. - Press
Build Settings
and scroll all the way down. - Add
TREE_SHAKE_ICONS
with a value offalse
as in the image below.
I hope this helps!