Skip to content

Working offline

Valentin Degenne edited this page Jan 17, 2024 · 4 revisions

If requesting a font over the network during development is not possible, rollup-plugin-md-icon comes with an offline stylesheet you can use instead:

1. Create a symbolic link inside your static directory:

cd public
ln -s ../node_modules/rollup-plugin-md-icon/all-symbols .

2. Update your index.html:

<head>
  <link
    id="symbols"
    href="./all-symbols/material-symbols.css"
    rel="stylesheet"
  />
</head>

Note: This link will need to be converted for production, you can use your own logic but the plugin exports transformation helpers that can be used for simplicity, all you need to do for now is to add id="symbols" attribute on the tag.

Clone this wiki locally