Cache icon bodies and components

This commit is contained in:
Max Veytsman
2022-09-02 07:20:50 -04:00
parent c61b1b39c4
commit 63b0668dcf
4 changed files with 81 additions and 14 deletions

View File

@ -18,12 +18,23 @@ defmodule Heroicons do
"""
# https://github.com/tailwindlabs/heroicons/releases
@latest_version "2.0.10"
@tmp_dir_name "heroicons-elixir"
use Application
require Logger
@doc false
def start(_type, _args) do
children = [
{Heroicons.IconCache, []}
]
opts = [strategy: :one_for_one, name: Heroicons.Supervisor]
Supervisor.start_link(children, opts)
end
@doc false
# Latest known version at the time of publishing.
def latest_version, do: @latest_version