Use reusable DiscoverText with count data

This commit is contained in:
2021-10-04 13:05:02 +02:00
parent 3b61ebd144
commit 0d622ef69f
3 changed files with 18 additions and 18 deletions

View File

@@ -0,0 +1,11 @@
<script lang="ts">
import { getContext } from 'svelte'
const { count }: any = getContext('global')
</script>
<p class="discover">
Discover <strong>{count.photos} homes</strong><br>
from <strong>{count.locations} cities</strong>
of <strong>{count.countries} countries</strong>
</p>