mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-22 16:56:50 +00:00
Make number of integrations dynamic on welcome screen (#28970)
This commit is contained in:
parent
4454427128
commit
3ba0b6c1b2
@ -3,8 +3,19 @@
|
||||
{{ site.description }}
|
||||
</p>
|
||||
|
||||
{%- assign tot = 0 -%}
|
||||
{%- for comp in site.integrations -%}
|
||||
{%- if comp.ha_category -%}
|
||||
{%- if comp.ha_category.first -%}
|
||||
{%- assign tot = tot | plus: comp.ha_category.size -%}
|
||||
{%- else -%}
|
||||
{%- assign tot = tot | plus: 1 -%}
|
||||
{%- endif -%}
|
||||
{%- endif %}
|
||||
{%- endfor -%}
|
||||
|
||||
<p class='hero-buttons'>
|
||||
<a href='/getting-started/'>Get started</a>
|
||||
<a href='https://demo.home-assistant.io' target='_blank'>View demo</a>
|
||||
<a href='/integrations/'>Browse 1900+ integrations</a>
|
||||
</p>
|
||||
<a href='/integrations/'>Browse {{ tot | minus: 1 | divided_by: 100 | round | times: 100 }}+ integrations</a>
|
||||
</p>
|
Loading…
x
Reference in New Issue
Block a user