-
Notifications
You must be signed in to change notification settings - Fork 2
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
Generate fontawesome icons #6
Comments
That could be useful, so I'd happy for you to integrate it. Looking at the linked JSON, it seems that you would need to put the attribution comment back in for compliance with the Font Awesome Free license, because it's not included in "raw". <!-- Font Awesome Free 5.15.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --> There's also a corresponding JSON file for the Pro license, but it's in a private repo, so it requires an access token to be appended to the address. I'm not sure if there's a convenient way of getting such a token within a Grav site, so I wouldn't consider this a requirement for inclusion.
An alternativeAlternatively, you could query the GitHub API to get the latest release, get the asset URL for the web version, then download it, unzip and just keep the SVGs. I'm not sure that piecing files back together from a JSON makes much sense when we can already get the files directly?
It might also be useful to have the option to upload a zip file and have the plugin automatically unzip it and move the SVGs to the right place. |
Thanks for your thoughts! I will think about it again and create a pull request draft for you to review. |
After some more thoughts about this topic, this is my conclusion: Requirements:
The only way I found to get access to the pro icons automatically is using npm. Fontawesome serves an official npm registry, where you can authenticate using the provided access token. These are my planned features:
Let me know what you think about this. |
Looks like a good plan. I shall look forward to your pull request. If you don't have Font Awesome Pro and need help testing it, just give me a shout. |
I created a merge request a while ago. This should still work |
Fontawesome provides a json file, what contains all icons as svg. Would you be interested in me integrating a functionality, that downloads the json file and generates svg files from it? This would be optional of course.
Tell me what you think about that :)
The text was updated successfully, but these errors were encountered: