AngularDart custom SVG mat-icon


I’m trying to register custom SVG icons to use as Material icons, specifically national flags.

In Angular I would use MatIconRegistry.addSvgIcon(..) in conjunction with DomSanitizer.

In AngularDart I’ve found DomSanitizationService, but so far I’m unable to find the equivalent of MatIconRegistry.


We use a mix-in if you want to override any material-icons in an angular_component here:

If you are just working with icons separately and it isn’t overriding one that is already included. I suggest just working with the SVG itself outside of material-icon.

Answered By – Ted Sander

Answer Checked By – Pedro (FlutterFixes Volunteer)

Leave a Reply

Your email address will not be published. Required fields are marked *