Learn the Date Object by Building a Date Formatter - Step 15

Tell us what’s happening:

I cant figure out the code to do it i have tried everything

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region

addEventListener.dateOptionsSelectElement

// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36

Challenge Information:

Learn the Date Object by Building a Date Formatter - Step 15

addEventListener needs to be called on an element. Let’s say your element is button, you would call button.addEventListener(). Inside the parenthesis you need a string that indicates the type of event, and then a function, which will be executed when the event happens