timmaffett / material_symbols_icons

Complete Flutter support for google's Material DesignMaterial Symbols Icons
Apache License 2.0
32 stars 5 forks source link

Font family packages/material_symbols_icons/MaterialSymbolsOutlined not found (404) after building for web #15

Closed suranjum closed 5 months ago

suranjum commented 5 months ago

When building the flutter app for web platform, although the ttf files are there in the assets/packages/material_symbols_icons/lib/fonts folder, the browser gives 404 error

timmaffett commented 5 months ago

I am at a bit of a loss. Perhaps you can provide more info? The package should work well in web builds and the example included in the package as a web build can be found here: Web Example

After reading your problem I also created an independent web build that references the current package version and also found no problems.

suranjum commented 5 months ago

Thank you. I hosted my application on another server and it is working now. Could it be something with the hosting or with the SSL. I don't have much knowledge about that.

timmaffett commented 5 months ago

I do have any particular knowledge about that, but one thing that may be a factor is that I use the font names as created by google and these are in format MaterialSymbolsXXXXXX[FILL,GRAD,opsz,wght].ttf and when these are URL encoded these names look like this (for the Sharp version:) MaterialSymbolsSharp%5BFILL%2CGRAD%2Copsz%2Cwght%5D.ttf perhaps some servers can have configurations which affect their retrieval - but honestly I have no real idea.

I am going to close this issue now that is it working for you.