New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mat-icon-import

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mat-icon-import

Include only used material icons in SVG format and reduce package size

  • 0.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
38
decreased by-35.59%
Maintainers
1
Weekly downloads
 
Created
Source

Import only used material (and custom) icons in Angular

Installation

npm i mat-icon-import
#or
yarn add mat-icon-import

Usage

Import the IconImportModule in your application module.

import { IconImportModule } from 'mat-icon-import';

@NgModule({
  imports: [ IconsModule.forRoot(['account_circle'], './assets/mat-icons') ]
})
export class AppModule {}

Register the icons where you need them. E.g. in the AppComponent to make it available in the complete application.

import { IconImportService } from 'mat-icon-import';

@Component({
  ...
})
export class AppComponent {
  constructor (private iconService: IconImportService) {
    this.iconService.register();
  }
}

Use the registered icons with

<mat-icon svgIcon="account_circle"></mat-icon>

Don't forget to include the MatIconModule from @angular/material.

Get in contact

  • Check the authors website
  • Get in touch via twitter or facebook

Keywords

FAQs

Package last updated on 26 Sep 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc