refactor(web): drop query entries

This commit is contained in:
wanhose 2022-05-23 13:29:58 +02:00
parent 72fc726f6e
commit 29b7ed7260

View File

@ -326,8 +326,7 @@
</div> </div>
<h3 class="font-medium mt-4 text-lg text-secondary">Large database</h3> <h3 class="font-medium mt-4 text-lg text-secondary">Large database</h3>
<p class="mt-2 text-gray-500"> <p class="mt-2 text-gray-500">
High cross-site support thanks to our almost <span id="entries"></span> database High cross-site support thanks to our almost 13000 database entries
entries
</p> </p>
</div> </div>
<div> <div>
@ -439,19 +438,5 @@
<a class="hover:underline" href="https://www.github.com/wanhose" target="_blank">wanhose</a> <a class="hover:underline" href="https://www.github.com/wanhose" target="_blank">wanhose</a>
</h5> </h5>
</footer> </footer>
<script>
const entriesElement = document.getElementById('entries');
const repositoryUrl = 'https://www.github.com/wanhose/cookie-dialog-monster';
(async () => {
try {
const entriesUrl = `${repositoryUrl}/data/elements.txt`;
const entriesLength = (await (await fetch(entriesUrl)).text()).split('\n').length;
entriesElement.textContent = entriesLength;
} catch {
entriesElement.textContent = 13000;
}
})();
</script>
</body> </body>
</html> </html>