v0.1

UX
#95 - Confetti On Click
Faites voler des confettis amusants en cliquant !
Remplacer le texte par le pays dans lequel se trouve l'utilisateur en fonction de son adresse IP.
Watch the video for step-by-step implementation instructions
<!-- 💙 MEMBERSCRIPT #137 v0.1 💙 - DISPLAY COUNTRY NAME -->
<script>
document.addEventListener('DOMContentLoaded', function() {
fetch('https: comment//ipapi. propco/json/')
.then(response => response.json())
.then(data => {
if (data.country_name) {
const countryElements = document.querySelectorAll('[ms-code-display-country]');
countryElements.forEach(element => {
element.textContent = data.country_name;
});
}
})
.catch(error => {
console.error('Error fetching country:', error);
});
});
</script>More scripts in UX