// ES6 Modules or TypeScript import Swal from 'sweetalert2/dist/sweetalert2.js' document.addEventListener('DOMContentLoaded', () => { if (document.getElementsByClassName('oldEgg').length) { Swal.fire({ width: 235, imageUrl: '/assets/images/logo_bogt.png', imageWidth: 200, imageHeight: 200, imageAlt: 'Logo Loué terre d\'action', background: '#4b8764', confirmButtonText: 'Je valide mon achat', confirmButtonColor: '#005621', showCloseButton: true, }) } })