Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove the font-awesome dependency #208

Open
NathanLovato opened this issue Jun 28, 2020 · 3 comments
Open

Remove the font-awesome dependency #208

NathanLovato opened this issue Jun 28, 2020 · 3 comments
Labels
css The task involves css. good first issue

Comments

@NathanLovato
Copy link
Collaborator

We're using font-awesome for a handful of icons on the website, but it's pretty heavy and delays full rendering of the page by quite a lot. In particular, the mobile menu icon.

@NathanLovato NathanLovato added the css The task involves css. label Jun 28, 2020
NathanLovato added a commit that referenced this issue Jun 28, 2020
@squirrellogic
Copy link

Are you planning on replacing FontAwesome with inline SVG, spans with SVG backgrounds, or a minimal custom icon font using something like Fontello?

@NathanLovato
Copy link
Collaborator Author

I'm unsure of the best approach there. In short, we use but a handful of fa icons: social networks, and maybe there are leftover link, book icons around the website; but we don't really need those. I think something like the tutorial menu could work, a plain svg object.

{{ with .Params.icon }}
<svg class="tut-menu-icon">
    <use xlink:href="/img/icons/menu-icons.svg#{{ . }}" />
</svg>
{{ end }}

@NathanLovato
Copy link
Collaborator Author

After checking, the only place we still use font-awesome on the main website is the main navigation, these 4 icons

Screenshot from 2020-10-22 13-34-05

There are some others but I'll clean them up now, they're all unnecessary

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
css The task involves css. good first issue
Projects
None yet
Development

No branches or pull requests

2 participants