Being someone who relies on to-do lists, I implemented a system where you can input tasks into a textbox and click the add button to see them listed below. However, I found it cumbersome to keep clicking the add button every time I wanted to quickly add multiple items. This led me to try implementing a feature that allows users to press Enter for quick additions. Despite several attempts using code from various sources like stackoverflow, I haven't been successful in getting it to work. Hence, I'm reaching out here for some assistance.
Please assist! [the end of the JavaScript part of the snippet is my most recent attempt]