Getting Started with Web Components
MDI can be used in conjunction with the SvgIcon Webcomponent. See the README in the repo for more usage information.
-
Install from NPM.
npm install @mdi/js @jamescoyle/svg-icon
-
Import into your project.
<!doctype html> <html> <head> <script type="module"> import '@jamescoyle/svg-icon' </script> </head> <body> <svg-icon type="mdi" path="M...z"></svg-icon> </body> </html>